We are trying to make one of our HR forms electronic by setting up a survey for people to complete a new starter form. What I want to do is call an SSRS subscription once the survey is complete which will email our HR department a form with the most recent data. I have the report setup and a subscription which I can trigger with a T-SQL command but what I can't figure out how to do is to call this when the survey is complete. I tried a SQL trigger on insert on the survey table but this is throwing errors and not saving the data - it also seems like data is inserted into the table before the survey is complete so I haven't tried to fix this method.
Does anyone know of a way that I can trigger a T-SQL command when the survey is completed? I am wondering if the end url can be used somehow but I'm not a programmer so don't know if this can be done in PHP for example.
That did occur to me but wasn't too sure on triggers. I actually took a brave pill and followed my own suggestion of PHP, found a sample file that runs a SQL command, changed it and it seems to work perfectly as I just force the End URL to open and pointed it at this PHP file that puts up a thank you message and runs the SQL.
In case anyone wants to do the same, here is the php
Yup, this is basically what i meant by the last suggestion.
Just in case: you can also pass (and catch by your script) any linking variables via exit URL also.
www.limesurvey.org/manual/URL_fields