Viewing 15 posts - 511 through 525 (of 1,048 total)
Hi Chris,
I have put some transaction statement in this script.
Is this right?
--ALTER Procedure [dbo].[BS_Voucher_CreateVoucher]
Declare@vouchertypeID int = 1,
@denomination int = 400,
@quantity int = 5,
@amountvalue int = 100,
@userid varchar(50) = 1,
@validateDays...
May 8, 2013 at 5:03 am
ChrisM@Work (5/8/2013)
Here's an excellent article to help you out:http://www.sqlservercentral.com/articles/T-SQL/62867/%5B/url%5D
Ok thanks a lot.. 🙂
will go through this article after completing transaction work with this script...
plz help me on this
May 8, 2013 at 4:38 am
ChrisM@Work (5/8/2013)
kapil_kk (5/8/2013)
...Yess it worked now 🙂
Thanks a lot..
can we move fwd now towards error handling and transaction
Sure. This bit first?
kapil_kk (5/8/2013)
May 8, 2013 at 4:26 am
kapil_kk (5/8/2013)
WITH E1(N) AS (
SELECT 1 UNION ALL...
May 8, 2013 at 3:53 am
ChrisM@Work (5/8/2013)
Here's an updated script which is adjusted to account for NULL values of VoucherValue:
--ALTER Procedure [dbo].[BS_Voucher_CreateVoucher]
DECLARE
@vouchertypeID int = 1,
@denomination int = 100,
@quantity int = 10,
@amountvalue int...
May 8, 2013 at 3:49 am
ChrisM@Work (5/8/2013)
kapil_kk (5/8/2013)
ChrisM@Work (5/8/2013)
The last SELECT in that script isSELECT VoucherNumber = @VoucherNumber, retval = @retval
What values are returned?
VoucherNumberretval
0VB
Thanks.
Either the table gv_vouchervalue doesn't have a row where voucherabbreviation =...
May 8, 2013 at 3:17 am
ChrisM@Work (5/8/2013)
The last SELECT in that script isSELECT VoucherNumber = @VoucherNumber, retval = @retval
What values are returned?
VoucherNumberretval
0VB
May 8, 2013 at 3:02 am
Also, I am not clear what this will do please explain.. I also want to learn error handling and transaction for this script:
WITH E1(N) AS (
SELECT 1 UNION ALL SELECT...
May 8, 2013 at 2:56 am
ChrisM@Work (5/8/2013)
--ALTER Procedure [dbo].[BS_Voucher_CreateVoucher]
DECLARE
@vouchertypeID int = 1,
@denomination int = 100,
@quantity int = 10,
@amountvalue...
May 8, 2013 at 2:38 am
ChrisM@Work (5/7/2013)
kapil_kk (5/7/2013)
ChrisM@Work (5/7/2013)
ALTER PROCEDURE [dbo].[BS_GetSTNValue]
--DECLARE
@pFromStore int = 1001,
@pToStore int = 1004,
@pSTN VARCHAR(20) = 0 output
AS
--BEGIN
DECLARE
@count INT...
May 7, 2013 at 11:53 pm
ChrisM@Work (5/7/2013)
ALTER Procedure [dbo].[BS_Voucher_CreateVoucher]
@vouchertypeID int = 1,
@denomination int = 100,
@quantity int = 10,
@amountvalue int = 100,
@userid...
May 7, 2013 at 11:47 pm
ChrisM@Work (5/7/2013)
ALTER Procedure [dbo].[BS_Voucher_CreateVoucher]
@vouchertypeID int = 1,
@denomination int = 100,
@quantity int = 10,
@amountvalue int = 100,
@userid varchar(50) = 1,
@validateDays int = 40
AS
--BEGIN
SET NOCOUNT ON;
DECLARE
@vouchertype varchar(20),
@transactionID varchar(20),
@count int =1,
@VoucherNumber...
May 7, 2013 at 8:19 am
The only issue I have in my script is how to handle transaction in this script.....
ALTER Procedure [dbo].[BS_Voucher_CreateVoucher]
@vouchertypeID int = 1,
@denomination int = 100,
@quantity int = 10,
@amountvalue int...
May 7, 2013 at 7:17 am
ChrisM@Work (5/7/2013)
'V'+@retval + Replace( Str( @max-2 + @count, 7), ' ', '0') ?
seems likely, but you have no...
May 7, 2013 at 7:15 am
ChrisM@Work (5/7/2013)
ALTER PROCEDURE [dbo].[BS_GetSTNValue]
--DECLARE
@pFromStore int = 1001,
@pToStore int = 1004,
@pSTN VARCHAR(20) = 0 output
AS
--BEGIN
DECLARE
@count INT = 0,
@AWBNo...
May 7, 2013 at 7:09 am
Viewing 15 posts - 511 through 525 (of 1,048 total)