1.sqlserver----sql语句: select * from DCS_RISK where 1=1 and SUPERINTENDENT_DPT_ID IN (select ID FROM ORG_DEPARTMENT WHERE CODEPATH LIKE'03.03.%') AND STATUS_NAME ='已确认' AND ISNULL(IS_CLOSED,0)=0 ORDER BY FIND_TIME DESC offset 0 rows fetch next 15 rows only postgresql-----sql语句: select * from "DCS_RISK" where 1=1 and "SUPERINTENDENT_DPT_ID" IN (select "ID" FROM "ORG_DEPARTMENT" WHERE "CODEPATH" LIKE'03.02.%') AND "STATUS_NAME" ='已确认' and ("IS_CLOSED" IS NULL OR "IS_CLOSED"=0) ORDER BY "FIND_TIME" DESC offset 0 rows fetch next 15 rows only 区别: 1.1 postgresql表名与字段名要用双引号 否则将会变成小写字符. 解决办法: 表名 SQLSERVER-> DCS_RISK == POSTGRESQL->”DCS_RISK”; 字段名 SQLSERVER-> STATUS_NAME == POSTGRESQL->”STATUS_NAME” 备注:(sqlserver 表中 表