March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi,
I'm using a direct query PBI SQL query with DECLARE statement.
It throws me an error saying that
Incorrect syntax near the keyqord DECLARE. Incorrect syntax near ')'
The SQL statement is as follows:
DECLARE @effect_date as date;
Set @effect_date= (select distinct effective_date from io.indirect_cost_ratio)
select * from io.inouttable
how can I get DECLARE statement to work in direct Query mode?
@Anonymous , where are you using this @effect_date date? this, you can use as a sub query.
Also checking after using this query is it still working on power bi service.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
124 | |
87 | |
85 | |
70 | |
51 |
User | Count |
---|---|
205 | |
153 | |
97 | |
79 | |
69 |