我在'PETA_PAGED'附近收到不正确的语法,在那儿我正在使用tenantaware数据库从数据库中获取数据,这是我正在使用的查询
select Id, Name from ListView where IsPartOf = 0
,执行此步骤后,将添加
"SELECT * FROM (SELECT ROW_NUMBER() OVER (ORDER BY NAME) PETA_RN, ID, NAME FROM LISTVIEW WHERE TenantId = '0000-000-0000-0000-0000' and ( ISPARTOF=0 ) PETA_PAGED ORDER BY NAME) PETA_RN, ID, NAME FROM LISTVIEW WHERE ISPARTOF=0 PETA_PAGED WHERE PETA_RN > @0 AND PETA_RN <= @1"
和异常,我得到 {“'PETA_PAGED'附近的语法不正确。”}
我正在使用的服务电话
var query = "select Id, Name from ListView where IsPartOf =0";
Page<Data.ListView> pagedData = this.TenantAwareDB.Page<Data.ListView>(pagedQuery.PageIndex, pagedQuery.PageSize, new Sql(query));