Luis Neves
wading in the water Posts:18
|
07-04-2012 12:51 AM |
|
I can't figure out how the SQL Failure Redirect URL option works, or is suposed to work...
Documentation is still for version 3.4 as far as i know, and of course there is no mention or tip on this.
It looked simple: put a URL for redirection in case of an error, which would stop the completion event (and hopefully all the next events).
I tried forcing different errors, for example Msg 50000, Level 14, State 1, Line 1Violation of UNIQUE KEY constraint 'constraint_id'. Cannot insert duplicate key in object 'table_name'. The duplicate key value is .... , but never worked.
The message i have for Submit Message After Save and the Email Completion event, are always triggered, and never saw the page corresponding to the SQL Failure Redirect (full) URL .
Plus, my SQL query is using TRY CATCH and Transactions, but i removed all this for testing, and the result was the same.
I'm not using a stored procedure on this case, because it would need many parameters for working.
Hope you can help me on this,
Luis Neves
|
|
|
|
|
Ryan Bakerink
river guide Posts:1900
|
07-06-2012 05:17 AM |
|
Hello Luis, Let's me to simplify your post and let me know which work flow you're trying: 1.) You want to have a user Submit the form. Once the form is submitted, you have a SQL Form completion event that fires. If it fails, then you want to redirect the user to a specific page. 2.) You have a SQL validation on the form enabled. When a user submits the form, the validation check takes place, and if it fails then you want to redirect the user. If your scenario isn't one of these two, please give me a brief 3-5 sentence summary of the workflow you need. -Ryan |
|
|
|
|
Luis Neves
wading in the water Posts:18
|
07-06-2012 06:08 AM |
|
I need the Nr. 1. workflow. But i need to guarantee that once the user is redirected to a specific page, none of the next completion events will be triggered. Luis |
|
|
|
|
Ryan Bakerink
river guide Posts:1900
|
07-06-2012 10:07 AM |
|
Hello Luis, Can you give me an example of what you're SQL Check is doing? Thanks, Ryan
|
|
|
|
|
Luis Neves
wading in the water Posts:18
|
07-06-2012 08:24 PM |
|
I am not doing an SQL Check on the SQL Completion Event, just using a sql statement to insert data to a table. What i thought i could accomplish, was in case of an SQL error (i.e: table that doesn't exist, or the SQL server not available, etc) the user would be redirected to a page. That's what i thought the SQL Failure Redirect URL option in the SQL Completion Event would do. |
|
|
|
|
Ryan Bakerink
river guide Posts:1900
|
07-09-2012 06:02 AM |
|
Hello Luis, Hmm.. interesting, thanks for bringing that feature to my attention. I've never used this feature before so had no idea that it existed. This must be a newer feature. From the sounds of this feature, you won't want to run a Try Catch in your SQL Completion Event because in order for this SQL Failure Redirect URL to work, you'll need an actual SQL Error to be invoked for this to work. Let me know if you're able to get this configured or if you have any questions. Thanks, Ryan |
|
|
|
|
Luis Neves
wading in the water Posts:18
|
07-09-2012 06:29 AM |
|
I believe is a new feature for v4.1 . But the real problem is, that i can't figure out how it works. I've tried with simple statements, like SELECT * FROM inexistent_table , without TRY CATCH (which i use to rollback transaction in case of an error, but still use RAISEERROR to raise out the exception ), an no matter how i do it, i can't make it to work. I would try on betasprings.com but the version i think it's 3.4 yet. If you can get me an example of a SQL Statement for me to test, maybe would be helpfull. I don't know if the URL has any restriction also. Thank you for your time, Luis |
|
|
|
|
Ryan Bakerink
river guide Posts:1900
|
07-09-2012 06:55 AM |
|
Hello Luis, I tried using the feature as well in an intuitive manner and it didn't work for me either. I'll look into our DF 4.1 User Guide(We're putting it together as we speak) to see if I can gain more insight on how to enable this control. Let me know if you have any questions, I'll post back in this thread once I have more info. Thanks, Ryan |
|
|
|
|
Chad Nash Posts:5260
|
07-09-2012 09:23 AM |
|
Hi guys - Just a heads up here... I reviewed the code and I believe that we did add this code in and I tested it to verify that it was working, however I just reviewed it again and I believe that we also added features to allow you to reference other SQL tokens responses that can be used into other SQL events. In other words, we added features to get the response that is returned, and if that response returns a value then the value can be used in the next SQL Event by using the $(EventName) etc... So... From what I see in the code, when we added this other feature we placed this within a try/catch error handling block in case no error is returned. Because of this though, I believe that it is not longer in the "other" try/catch block which is actually making use of this feature. So... That is my first guess because I know these enhancements came after the enhancement/feature you are referring to here. If you would like you can open a support ticket at http://support.datasprings.com and just mentioned this thread... and then I can get a patch out to you shortly and we can also follow up with this thread once we have released it for everyone. Thanks, -Chad |
|
|
|
|
Luis Neves
wading in the water Posts:18
|
07-10-2012 07:00 AM |
|
Hi Chad,
I opened a support ticket for this. Thank you
|
|
|
|
|
Luis Neves
wading in the water Posts:18
|
07-17-2012 12:50 AM |
|
Hi, No news about this issue? |
|
|
|
|
Mike Stuart
wading in the water Posts:25
|
07-17-2012 01:27 AM |
|
Chad We were counting on this feature working, can you let us know when it will be fixed? Now we are concerned reading this thread that this important failure indicator is no longer working. Mike |
|
|
|
|
Chad Nash Posts:5260
|
07-18-2012 10:01 AM |
|
Hi Luis / Mike - I should have a patch by the end of this week. Mike, I will email you separately... The build you have might actually have this working unless you upgraded to the full release as this last enhancement went out then. Either way, I am planning to have this fixed by the end of day on Friday. Thanks, -Chad
|
|
|
|
|
Mike Stuart
wading in the water Posts:25
|
08-19-2012 09:02 PM |
|
Did you send patch? I have not seen it yet/ |
|
|
|
|
Chad Nash Posts:5260
|
09-04-2012 04:18 PM |
|
Hi Mike - Yes, I just sent this over to you. Thanks, Chad
|
|
|
|
|