Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase ««12

Store Procedure Expand / Collapse
Author
Message
Posted Monday, February 9, 2009 6:55 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Thursday, February 12, 2009 10:38 PM
Points: 12, Visits: 44
Hi Lynn

Sorry, I did not answer your question.

The reason I looked for is as below

1. I need to perform certain validation on database if it is called
independantly.

2. If it is called from any parent procedure, the validation may not
be required.

Previously I was passing a parameter Y/N.
Now by using the @@NESTVALUE , I am able to achive this.

Thanks,
Venkat

Post #652771
Posted Tuesday, February 10, 2009 10:11 AM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Today @ 6:48 PM
Points: 20,734, Visits: 32,499
Thank you. Now it all makes sense and using @@nestlevel does look like the best option in this case.

Something new learned, good that is.



Lynn Pettis

For better assistance in answering your questions, click here
For tips to get better help with Performance Problems, click here
For Running Totals and its variations, click here or when working with partitioned tables
For more about Tally Tables, click here
For more about Cross Tabs and Pivots, click here and here
Managing Transaction Logs

SQL Musings from the Desert Fountain Valley SQL (My Mirror Blog)
Post #653959
« Prev Topic | Next Topic »

Add to briefcase ««12

Permissions Expand / Collapse