SELECT.....

 (v1.PCG like 'n0%'
or
v1.PCG like 'n1%'
or
v1.PCG like 'n2%'
or
v1.PCG like 'n3%'
or
v1.PCG like 'n4%'
or
v1.PCG like 'n5%'
or v1.PCG='N63Af1')

and v1.PCG not like 'N2D%'
and v1.PCG not like 'N2E%'
and v1.PCG not like 'N2C%'
and v1.PCG not like 'N2F%'
and v1.PCG not like 'N2J%'
and v1.PCG not like 'N2K%'
and v1.PCG not like 'N2U%'
and v1.PCG not like 'N2GC%'
and v1.PCG not like 'N2GD%'
and v1.PCG not like 'N2GH%'
and v1.PCG not like 'N2GJ%'
and v1.PCG not like 'N2GK%'
) as 'Value Of PN Orders',

from........
我已经完成了代码,但是正在尝试找到一种更有效的方法,我看了一下,但是找不到其他方法……有什么建议吗?

最佳答案

Like支持字符类。

where v1.PCG like 'n[12345]%'

10-08 07:14