I tried both of your suggestions that you list below and unfortunately
neither of them work. Any other suggestions?
> A type mismatch error means that you are passing a type that is incompatible
> with the type being expected.
[quoted text clipped - 32 lines]
> > above command line in query analyzer so that a record was inserted into the
> > table. Can anyone help me with the syntax above?
S.Y.M. Wong-A-Ton - 13 Jan 2006 19:22 GMT
No, but I do have two questions: Why did you set id as an output parameter in
your stored procedure? And is a row inserted if you change your stored
procedure to only accept empid, so only the input parameter?
S.Y.M. Wong-A-Ton
> I tried both of your suggestions that you list below and unfortunately
> neither of them work. Any other suggestions?
[quoted text clipped - 35 lines]
> > > above command line in query analyzer so that a record was inserted into the
> > > table. Can anyone help me with the syntax above?
S.Y.M. Wong-A-Ton - 14 Jan 2006 11:05 GMT
FWIW, I was able to successfully insert and update records by using a stored
procedure as described in the knowledge base article (both with script and
with C# code). Adding an output parameter to the stored procedure did not
impede the update. Passing a string while an int was expected by the stored
procedure, produced an error, but no explicit "type mismatch" error as you
mentioned.
I didn't find a way to retrieve the value of the output parameter by using
the same syntax as in your code. According to me this is not the correct way
to retrieve the value of an output parameter. The common way is to set
parameters on a command object. However, the query adapter does not offer
this possibility or I missed it, somehow.
S.Y.M. Wong-A-Ton
> I tried both of your suggestions that you list below and unfortunately
> neither of them work. Any other suggestions?
[quoted text clipped - 35 lines]
> > > above command line in query analyzer so that a record was inserted into the
> > > table. Can anyone help me with the syntax above?