Created
December 22, 2018 16:30
-
-
Save spinningcat/0c4415ba4d9f861051566b28114cdb9e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
with cte1 AS | |
(select cd.HASTA_ADI, concat(cd .HASTA_ADI, ' ', cd.HASTA_SOYADI) as HASTAADISOYADI, case when min(md.MAP) > | |
min(md.NIMAP then min(md.MAP) else min(md.NIMAP) end as mapnimapvalue from MonitorData md inner join | |
ClientPatientDemograficData as cd on md.PID = cd.HASTA_ID where md.DateMonitor <= DATEADD(hour, -1, getdate()) | |
AND md.DateMonitor >= DATEADD(day, -1, GETDATE()) group by cd.HASTA_ADI, cd.HASTA_SOYADI | |
) select cte1*, case when mapnimapvalue < 90 then 1 else 2 end as point from cte1; | |
error: [S0001][102] Incorrect syntax near ','. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment