all groups > sql server programming > november 2003 >
You're in the

sql server programming

group:

Updating record in a SP!


Updating record in a SP! lars NO[at]SPAM bas.no
11/18/2003 11:51:44 PM
sql server programming:
Hello!

Is it possible to update records being shown in a grid when using an
advanced SP, or do I have to create another SP to update the record?

Using ADO to update, but that shouldn't be a problem I hope.


Re: Updating record in a SP! Tomislav Kralj
11/19/2003 9:02:50 AM
It should be possible in cases of simple query inside the sp. If you use
query that make joins to other tables you might not be able to update data
in the grid. One solution might be to create INSTEAD OF trigger on the
tables referenced in query (the ones that you update through grid). Do you
get any errors ?. Please post errors you get when you try to update the
grid.


--
Regards,
Tomislav Kralj
tomislav.kralj1@zg.tel.hr


[quoted text, click to view]

Re: Updating record in a SP! Lars Grøtteland
11/19/2003 9:13:29 AM
thanks

It's a pretty advanced table with six joins inside it so you answered my
question - thanks!

--


- Lars


[quoted text, click to view]

Re: Updating record in a SP! Lars Grøtteland
11/19/2003 9:20:30 AM
well not table, but query with six joins inside it.

--


- Lars


[quoted text, click to view]

Re: Updating record in a SP! Vinodk
11/19/2003 1:31:06 PM
Can you illustrate with a flow example. I think the question is not so
clear.

BTW if you are asking if we can update the record selected in a grid to a DB
... Then yes it is possible, with identifying the record selected and
inserting into the appropriate tables using an existing or new SPs.

--
HTH,
Vinod Kumar
MCSE, DBA, MCAD, MCSD
http://www.extremeexperts.com

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp


[quoted text, click to view]

AddThis Social Bookmark Button