存储错误,帮我看看吧
create proc InquiryTO(@StartStop varchar(32),@EndStop varchar(32))as
begin
select
sr1.Stop as 起始站点,
sr2.Stop as 目的站点,
sr1.Route as 乘坐线路,
sr2.Position-sr1.Position as 经过的站点数
from
stop_route sr1,
stop_route sr2
where
sr1.Route=sr2.Route
and sr1.Position<sr2.Position
and sr1.Stop=@StarStop
and sr2.Stop=@EndStop
end
错误提示:消息 137,级别 15,状态 2,过程 InquiryTO,第 18 行
必须声明标量变量 "@StarStop"。