SQL BETWEEN in HANA

做~自己de王妃 提交于 2019-12-11 19:11:20

问题


I have to write a condition where I have to check a "DATE" lie beween two other date values as shown in the example:

var_out= CE_PROJECTION(:table1,["col1","col2","col3","col4"],  ' " col2"  BETWEEN "col3" AND "col4" ' );

But this throws me an error SQL: transaction rolled back by an internal error: Syntax Error in filter expression

Could anyone suggest the right syntax for this?

Thanks


回答1:


Between is not supported in the filter expression of CE_PROJECTION.

You can try

var_out= CE_PROJECTION(:table1,["col1","col2","col3","col4"],  ' "col2" >= "col3" AND "col2" <= "col4" ' );

Hope it helps.



来源:https://stackoverflow.com/questions/21136184/sql-between-in-hana

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!