use TEST
go
create PROCEDURE [dbo].[SP_物料出入库周期]
(
@起始日期 VARCHAR(8),
@结束日期 VARCHAR(8)
@id char(3) output
)
AS
BEGIN
SET NOCOUNT ON; --当 SET NOCOUNT 为 ON 时,不返回计数。当 SET NOCOUNT 为 OFF 时,返回计数。
----------------删除临时表------------------------------------
--if object_id('tempdb..#TempA') is not null drop table #TempA;
--------------------------------------------------------------
select
INVMC.MC001 as '品号'
,MB002 as '品名'
,INVMC.MC002 as '仓库'
,CMSMC.MC002 as '仓库名称'
,INVMC.MC007 as '库存数量'
,INVMC.MC011 as '上次盘点日'
,INVMC.MC012 as '最近入库日'
,INVMC.MC013 as '最近出库日'
from INVMC ,INVMB ,CMSMC
where
INVMC.MC001 = MB001 and INVMC.MC002 = CMSMC.MC001
and ((INVMC.MC012 BETWEEN @起始日期 AND @结束日期 ) or (INVMC.MC013 BETWEEN @起始日期 AND @结束日期 ))
and INVMC.MC002 in ('101','102','103','104','106','110')
---------------------------------------------------------------
End
---------------------------------------------------------------
declare @id char(3)
exec TEST..SP_ASCII 90,90,57,@d = @id output
select @id as 序号
免责声明:
① 本站未注明“稿件来源”的信息均来自网络整理。其文字、图片和音视频稿件的所属权归原作者所有。本站收集整理出于非商业性的教育和科研之目的,并不意味着本站赞同其观点或证实其内容的真实性。仅作为临时的测试数据,供内部测试之用。本站并未授权任何人以任何方式主动获取本站任何信息。
② 本站未注明“稿件来源”的临时测试数据将在测试完成后最终做删除处理。有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341