Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Execution of SQL Server Stored Procedure
Message
 
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00867969
Message ID:
00867989
Views:
25
Ok thanks!

>You don't need extra locks because everything is done in one UPDATE command.
>
>>Thanks Sergey!
>>
>>How about using RowLock? Do you think it will also help?
>>
>>>You've to modify it a little bit to avoid duplicates. It's also better to return value as an output parameter.
CREATE PROCEDURE GetSeriesNo
>>>	(@doccode varchar(10), @seriesno int OUTPUT)
>>>AS
>>>BEGIN
>>>--	DECLARE @seriesno int
>>>	Update ccdoc
>>>		Set seriesno = seriesno + 1, @seriesno = seriesno + 1
>>>		Where doccode = @doccode
>>>--	SELECT @seriesno
>>>END
>>>
JESS S. BANAGA
Project Leader - SDD division
...shifting from VFP to C#.Net

CHARISMA simply means: "Be more concerned about making others feel good about themselves than you are in making them feel good about you."
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform