Comments
2 comments
-
On further review, it seems to be a bug with the option:
General, Commas, Multiple Line Statements
The two "Space after comma" settings. When they are not checked, there will be no space between the As and the first value. For example:select 'hi' as fred, 'bye' as barney from testis layed out as:select 'hi' as fred , 'bye'as barney from test
Apparenly it is removing the space from the wrong location. So the workaround is to turn on the Space after comma. Not a big deal, but it looks funny :select 'hi' as fred , 'bye' as barney from test -
drsql wrote:...
Note that endas should be two words, "end as"
Thank you, this is a bug, quite a scary one
. It will be fixed for the final release.
Many thanks for reporting this,
Andras
Add comment
Please sign in to leave a comment.
select value, case when datediff(yyyy, p.TransactionDate, getdate()) = 0 then sum(p.Amount) end as CurrentYearValue from tableNameThe following is the result:
select value , case when datediff(yyyy, p.TransactionDate, getdate()) = 0 then sum(p.Amount) endas CurrentYearValue from tableNameNote that endas should be two words, "end as"