Forum Discussion
Anonymous
4 years agoNot applicable
DECLARE statement in PBI using DirectQuery
Hi, I'm using a direct query SQL in PBI. While using a DECLARE statement, it throws an error Incorrect syntax near the keyqord 'DECLARE'. Incorrect syntax near ')' My SQL statement is as fol...
smpa01
4 years agoCommunity Champion
Anonymous can you try this
DECLARE @effect_date date= (select distinct effective_date from in.input_table)
select * from abc
join ....
group by....