How to avoid a rename step in #PowerQuery when you use Table.FromList – #PowerBI

Here is a tip that reduces your Power Query steps with 1 step less.

When I build date tables I typically use the function List.Dates to create a list of dates.

As I want it as a table I use the Ribbon interface to convert the list of dates into a table

Which then gives med a table with on column called Column1

Instead of renaming the column using the interface like this

And thereby getting an extra step “Renamed Columns”

You should modify the third argument in the Table.FromList and specify the name of the column in a list

= Table.FromList(Source, Splitter.SplitByNothing(), {“Date”}, null, ExtraValues.Error)

Which will reduce the number of steps with 1.

3 thoughts on “How to avoid a rename step in #PowerQuery when you use Table.FromList – #PowerBI

  1. Pingback: Avoiding a Rename Step with Table.FromList – Curated SQL

  2. Hi Erik,
    Great post, thanks for sharing. With my research I stumbled upon your article.

    If you like you can even include the data type in the Table.FromList function. I’m currently writing an article on this. For example, the following codes returns the data type too:

    = Table.FromList(
    {“Apple”, “Prume” },
    type table[Product=Text.Type] // specifies column type and name

  3. Pingback: #PowerQuery – Convert a referenced query column to a table without Table.FromList() – Magic trick – Erik Svensen – Blog about Power BI, Power Apps, Power Query

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s