Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago

Seeing my database's structure with Power Query

Hello,

 

I am an IT intern with some experience in databases but not a whole lot with Excel, and none with Power Query.
My small company requires me to make some pivot tables with relevant info from their SQL database, however in order to do that I would like first to have a clear idea of what the DB's structure is like.

I would like to display the database's general structure with power query, using an ODBC. However all I get when inputting the datasource is basically a list of all the tables in the DB.

 
 

Any ideas or suggestions? Thank you

 

 

3 Replies

  • CNENFRNL's avatar
    CNENFRNL
    Community Champion

    Anonymous , you're barking up the wrong tree. Power Query isn't a db management software; on the contrary, ask db admin for data dictionary or something similar.

  • Anonymous's avatar
    Anonymous
    Not applicable

    I would add a column of the column names of each table in the dB. PQ is actually THE BEST way to get an idea of what's in the database. Once you have your list of Db tables:

    NewColumn = Table.AddColumn(LastStepName, "Columns", each Table.ColumnNames(_[DataTableName]))

    This will list the columns in each table, right next to its table name. When I was new, I did this all the time.

    --Nate

  • Anonymous's avatar
    Anonymous
    Not applicable

    Anonymous 

    PQ is not a db software, instead it is a business intelligence tool used to transform and shape data from different sources. Please first read the following blog:

    The Complete Guide to Power Query | How To Excel

     


    Paul Zheng _ Community Support Team
    If this post helps, please Accept it as the solution to help the other members find it more quickly.