12
12
12
1
]]>
12
=TO_DATE(?,'yyyymmdd') AND pbrq<(TO_DATE(?,'yyyymmdd')+1)
AND ygbm=?
AND sd=?
]]>
12
12
12
12
12
4
SELECT cur_seq FROM TABLE(get_next_val_new(?,?,?,?,?))
12
12
12
4
4
'4' or num.YYTJ IS NULL)
AND sft.sd IN ('1','2','3','8')
AND (num.upkey IS NOT NULL AND num.upkey<>'-1')
AND (num.hyzt='2') --2已预约
AND sft.choscode=?
AND sft.ygbm=?
AND sft.pbrq>=TO_DATE(?,'yyyymmdd') AND sft.pbrq<(TO_DATE(?,'yyyymmdd')+1)
ORDER BY sd,yyh
]]>
12
12
12
12