ByzantianX
Programmer
- Dec 18, 2000
- 103
I'm using stored procedure for updating table (calling the procedure from vb class module and passing the values). Sometimes I'm passing one and sometimes more than one value. If I use default values for parameters in stored procedure and pass one value I will get the error message. Other words saying, I have to either pass all the values for parameters or none.Is there any solution for that problem?
the code would be like this:
create sp1
@prm1 int=5,@prm2 bit=true
as
update tbl
set fld1=@prm1,@fld2=@prm2
return
the code would be like this:
create sp1
@prm1 int=5,@prm2 bit=true
as
update tbl
set fld1=@prm1,@fld2=@prm2
return