I have two tables: PROD and CUST On running the below query in SQL and SYBASE, it works. Oracle is not giving any results.
select * FROM PROD
where PROD.SECID NOT IN (SELECT CUST.SECID FROM CUST WHERE SECID <> '')
Run Code Online (Sandbox Code Playgroud)
NOTE: PROD.SECID has all null values. CUST.SECID has all non null values(valid values).
<>'' doesn't fetch any records from inner subquery so i changed it to IS NOT NULL and now it fetches the results.
但问题是,当查询作为一个整体运行时,它不会给出任何应有的结果。
我正在从数据库表(ABCD)查询数据,并希望将其存储在某个 DataStructure 中,然后逐行读取它并对值执行计算并使用修改后的值更新数据结构。
最后,一旦所有行的计算完成,我将使用每行的更新值更新 ABCD 表。
请建议要使用的可提供最佳性能的数据结构。我正在考虑使用二维数组或数据表。