R
R9
Unregistered / Unconfirmed
GUEST, unregistred user!
存储过程:
CREATE PROCEDURE 医生表p @uid varchar(30), @pwd varchar(30), @医生编号 int, @科室编号 int,
@医生姓名 varchar(8) = , @操作 varchar(4)
AS Begin
SET NOCOUNT ON
declare @test int, @dsql varchar(1000)
EXEC @test = 登录p @uid, @pwd, 'p2'
if @test = -1 return 50
if @操作 = '刷新' begin
set @dsql = 'select * from 医生表 where 1=1 '
EXEC(@dsql)
delphi调用:
ads.ProcedureName := '医生表p';
ads.Parameters.Refresh;
ads.Parameters.ParamValues['@uid']:='aa';
ads.Parameters.ParamValues['@pwd']:='bb';
ads.Parameters.ParamValues['@操作']:='刷新';
ads.Parameters.ParamValues['@医生编号']:=1;
ads.Parameters.ParamValues['@科室编号']:='';
ads.Parameters.ParamValues['@医生姓名']:='';
ads.Open;
编译到 ['@医生姓名'] 错误:一个错误类型的值!
谁来帮我看看?
CREATE PROCEDURE 医生表p @uid varchar(30), @pwd varchar(30), @医生编号 int, @科室编号 int,
@医生姓名 varchar(8) = , @操作 varchar(4)
AS Begin
SET NOCOUNT ON
declare @test int, @dsql varchar(1000)
EXEC @test = 登录p @uid, @pwd, 'p2'
if @test = -1 return 50
if @操作 = '刷新' begin
set @dsql = 'select * from 医生表 where 1=1 '
EXEC(@dsql)
delphi调用:
ads.ProcedureName := '医生表p';
ads.Parameters.Refresh;
ads.Parameters.ParamValues['@uid']:='aa';
ads.Parameters.ParamValues['@pwd']:='bb';
ads.Parameters.ParamValues['@操作']:='刷新';
ads.Parameters.ParamValues['@医生编号']:=1;
ads.Parameters.ParamValues['@科室编号']:='';
ads.Parameters.ParamValues['@医生姓名']:='';
ads.Open;
编译到 ['@医生姓名'] 错误:一个错误类型的值!
谁来帮我看看?