📄 查看未销未领未报损的机子所有信息.sql
字号:
/*********************************
查看未销/未领/未报损/的机子所有信息
*************************************/
declare @act int --1为按类型2按串号3所有
declare @val char(5)--型号
set @act=1
set @val='XH007'
--set @val='234234'
if @act=1
begin
SELECT *
FROM vAllSj a
where a.fid not in (select fcode from thxc) and a.fid not in (select fhrxx from tgtlh) and a.fid not in(select fhrxx from tbs) and a.fsjxhid=@val
end
if @act=2
begin
SELECT *
FROM vAllSj a
where a.fid not in (select fcode from thxc) and a.fid not in (select fhrxx from tgtlh) and a.fid not in(select fhrxx from tbs) and ltrim(rtrim(a.fno))=ltrim(rtrim(@val))
end
if @act=3
begin
SELECT *
FROM vAllSj a
where a.fid not in (select fcode from thxc) and a.fid not in (select fhrxx from tgtlh) and a.fid not in(select fhrxx from tbs)
end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -