OData常见用法

eg:http://localhost:9999/oq/XXXXXX?$orderby=DataDate&$top=10&$filter=((DataDate ge 2021-05-20) and (DataDate lt 2021-05-21)) and ((Gender eq 0) and (((IsUse eq true) and (InState eq 1)) or ((IsUse eq true) and (InState eq 0)) or ((IsUse eq true) and (InState eq 2))))&$count=false&$skip=0
 

 

 

其他问题

odata去掉页面对排序 会默认按主键排序
此时可以考虑生成行号 行号作为主键排序
select cast( (@i:=@i+1) as SIGNED ) as RowIndex,ttt.* from(...) ttt,(select @i:=0) b

 

posted @ 2023-01-10 17:13  阳光下的行者  阅读(130)  评论(0编辑  收藏  举报