Could it be as simple as this? :unsure:
if Project = 105000 and Intercompany Loan Accounts not between 125100 - 125950
begin
SET @Error = 15
SET @error_message = 'AR Invoice Lines - Can Only use this GL Accounts with Intercompany Loan Accounts'
end
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/