The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hi there,
I have two tables. They both contain a list of data sources that my code loops through
Currently my setup is like so
let Source = Table_A,
#"Added Custom" = Table.AddColumn(Source, "Custom", each myFunction_f([mySources])),
with me manually changing the value to Table_B when I am ready to push to production. However, I have a dozen or so queries that I am having to manually change. Ideally i would like to do this via a parameter which would allow me to toggle between Table_A and Table_B.
I have the below setup, but it's erroring out. How would I correctly do this?
Desired Code:
let Source = myParam, #"Added Custom" = Table.AddColumn(Source, "Custom", each myFunction_f([mySources])),
Error message when using 'Desired Code'
Solved! Go to Solution.
You may use Record.Field function.
Source = Record.Field(#shared, myParam),
You may use Record.Field function.
Source = Record.Field(#shared, myParam),
User | Count |
---|---|
68 | |
63 | |
59 | |
54 | |
28 |
User | Count |
---|---|
182 | |
81 | |
64 | |
46 | |
38 |