求告知问题
sqlserver吧
全部回复
仅看楼主
level 5
create procedure one @商品号 int,
@年份 date ,
@利润 int output
as
begin
declare
@销售数量 int,@销售单价 int,@单价 int
select @单价=单价 from 商品表 where @商品号=商品号;
select @销售单价=销售单价, @销售数量=销售数量 from 销售表 where @商品号=商品号 and @年份=销售时间
end
if @单价 is null
rollback;
return;
if @销售单价 is null
rollback;
return;
set @利润=@销售数量*(@销售单价-@单价)
go
2017年02月14日 02点02分 1
level 5
执行过程中显示varchar 转换int出错是什么情况。。求大神告知
2017年02月14日 02点02分 2
1