Tagged: sqlserver connect behavior
- June 29, 2012 at 10:22 pm #1051
Is there a way to capture the error returned by SQL Server in a Connect behavior? I realize that the error message will pop up (if I have “Show error messages” is checked) but I’d like to perform certain actions based on what the SQL error is.
For example, I created a test stored procedure that simply does a select on a bogus table, yielding an “Invalid object name ‘bogustable'” message when executed. But none of the “Behavior’s last error/return value/successful” options in the Special list return that message or anything like it after the Connect is executed. Is there a way to capture this?June 29, 2012 at 11:16 pm #6168
Dennis @ PerfectFormsBlockedJuly 3, 2012 at 3:28 pm #6169
Thanks, but I was looking for something upon which I could act within the form when SQL returns a specific error, like if SQL returned a primary key violation I could tell the user a record already exists and to change their data.
You must be logged in to reply to this topic.