Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
Anonymous
Not applicable

why isn't this working - keep getting error: "Name" wasn't recognized

First off - when is MSFT going to allow Paste operations on this site? I don't think it's an employer firewall issue as I'm able to paste code into other tech forums.
Ok - I have a string of M code which doesn't have any Syntax errors showing in Advanced Editor - but I keep getting the folowing error message:  
"An error occurred in teh the " query. Expression.Error: The name 'Merged Queries2' wasn't recognized. Make sure it's spelled correctly."
Here are the two pertinent lines in my M code:
#"Merged Queries2" = Table.NestedJoin(#"Change Index Type", {"Temp"}, #"Reporting Dates", {"Index"}, "Reporting Dates", JoinKind.LeftOuter),

#"Expanded Reporting Dates" = Table.ExpandTableColumn(#"Merged Queries2", "Reporting Dates", {"Reporting Month"}, {Reporting Month}),

 

Appreciate any insights!

Thanks!

Steve 

 

1 ACCEPTED SOLUTION
KNP
Super User
Super User

Pasting also works fine for me, for pretty much all objects, text, images etc.

 

As far as your query goes, I think you're missing some quotes, although I don't think it explains that error.

 

#"Merged Queries2" = Table.NestedJoin(#"Change Index Type", {"Temp"}, #"Reporting Dates", {"Index"}, "Reporting Dates", JoinKind.LeftOuter),

#"Expanded Reporting Dates" = Table.ExpandTableColumn(#"Merged Queries2", "Reporting Dates", {"Reporting Month"}, {"Reporting Month"}),

 

 

Have I solved your problem?
Please click Accept as Solution so I don't keep coming back to this post, oh yeah, others may find it useful also ;).
xOIEmaj

If you found this post helpful, please give Kudos.
It gives me a sense of instant gratification and, if you give me Kudos enough times, magical unicorns will appear on your screen.
If you find my signature vaguely amusing, please give Kudos.
image
fabric-SUbadge
Proud to be a Super User!

View solution in original post

4 REPLIES 4
KNP
Super User
Super User

Pasting also works fine for me, for pretty much all objects, text, images etc.

 

As far as your query goes, I think you're missing some quotes, although I don't think it explains that error.

 

#"Merged Queries2" = Table.NestedJoin(#"Change Index Type", {"Temp"}, #"Reporting Dates", {"Index"}, "Reporting Dates", JoinKind.LeftOuter),

#"Expanded Reporting Dates" = Table.ExpandTableColumn(#"Merged Queries2", "Reporting Dates", {"Reporting Month"}, {"Reporting Month"}),

 

 

Have I solved your problem?
Please click Accept as Solution so I don't keep coming back to this post, oh yeah, others may find it useful also ;).
xOIEmaj

If you found this post helpful, please give Kudos.
It gives me a sense of instant gratification and, if you give me Kudos enough times, magical unicorns will appear on your screen.
If you find my signature vaguely amusing, please give Kudos.
image
fabric-SUbadge
Proud to be a Super User!
Anonymous
Not applicable

thansk all - I'll try adding the missing quotes and circle back

BTW - I've determined that it is actually my employer that is blocking my ability to paste any thing into tech forums - total bummer but IIWII

ronrsnfld
Super User
Super User

I, too, have had no problem pasting either code or pictures onto this site.  Which line/applied step is first showing the error?  In my coding, that error usually means I neglected to enclose something within quotation marks, or some other typo, so the compiler can't find a variable with that name.

AlexisOlson
Super User
Super User

FWIW, I've never had issues pasting code here.

 

I don't see anything wrong with the lines you posted. Can you try hitting Refresh Preview and if that doesn't do anything share the rest of your query M code.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors
Top Kudoed Authors