我有一个查询,我需要将其转换为 SQL。一段时间以来一直在搜索这样做,但这里没有任何成功是 ORACLE 查询
SELECT
DRKY AS REASON_CODE,
DRDL01 AS DESCRIPTION
FROM shema.SourceTable
WHERE drsy = '00' AND DRDL01 IS NOT NULL AND (drrt = 'W4' OR drrt = 'W5') and NVL ( trim(DRKY), '000') = '801';
这是我的不返回值的 Linq 查询
var RJDEReasonCode = from a in JTable.SourceTable
where
a.DRSY.Equals( "00") &&
a.DRDL01 != null &&
(a.DRRT.Equals( "W4") ||
a.DRRT.Equals( "W5")) &&
a.DRKY.Equals( "801") // here is where the problem is tried many things but nothing has worked so far.
select new
{
CATEGORY_CODE = a.DRRT,
REASON_CODE = a.DRKY,
DESCRIPTION = a.DRDL01
};