find first b no-lock where b.a = variable
and (b.b = variable7 or b.b = variable8) no-error.
find first a no-lock where a.a = variable
and a.b = variable2
and a.c = variable3
and ((a.d <> variable4 and a.e <> variable5 and a.f <> variable6)
or available b)
no-error.
3 回答
鉴于您想要创建的语句,我建议采用以下两步过程:
不要过多考虑MS SQL查询或一般脚本查询 .
比如每个test1 no-lock其中test1.a = var1和test1.b = var2 no-error .
与找到第一个test1 no-lock相同,其中test1.a = var1和(test1.b = var2或test1.c = var3)无错误 . //它一次只给你一行 .
我相信你要找的声明是'可以找到' .