Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Logic problem
Message
 
 
To
All
General information
Forum:
Microsoft SQL Server
Category:
Other
Title:
Logic problem
Environment versions
SQL Server:
SQL Server 2005
Miscellaneous
Thread ID:
01337628
Message ID:
01337628
Views:
46
Hi everybody,

I have a stored procedure that accepts lots of parameters and called PeopleInsert. I have another procedure that is called SaveApprovedPeople.

In the SaveApprovedPeople procedure it first updates registration table (sets status to approved) and then inserts into People and related tables information from registration table. The logic of insert should be the same as PeopleInsert (except that instead of parameters I'm using Registration table record).

My question is - how should I somehow incorporate the logic of one procedure into another? Because I found that there is no error checking in SaveApprovedPeople and we have at least 2 business rules - no same userID and no same people to be inserted.

These rules I currently have implemented inside the stored procedure - may be this is my error? May be I needed to implement them as triggers?

Thanks in advance.
If it's not broken, fix it until it is.


My Blog
Reply
Map
View

Click here to load this message in the networking platform