SqlDeveloper在脚本查询中检查不带IS NULL子句的空值

2024-10-03 06:18:28 发布

您现在位置:Python中文网/ 问答频道 /正文

for circuit in allCircuit:                   # a cvs of 4 columns

    part = circuit.split(",")

    res = cur.execute("""SELECT col4 from ATable WHERE
    ( "col1" = :a
    AND "col2" = :b
    AND "col3" = :c
    AND "col4" = :d) 
    ORDER BY col4""",a = part[0], b= part[1], c = part[2], d = part[3])

第[0]部分到第[3]部分可能包含空(类型化)值。你知道吗

但是甲骨文不接受where子句,比如:

其中“col1”=空

其中“col1”为空

是吗

如何将“isnull”stmt放在脚本查询中而不是“col=NULL”?你知道吗


Tags: columnsandofinforexecuterescol1