sqlReports 5.4.1 is Now Available

sqlReports 5.4.1 is now available and fixes a bug that affects all versions of sqlReports going back to sqlReports 3.  The bug relates to the Open in New Window feature, which can be enabled by checking a box in the Edit, Results Page area for a report.  When one runs the report and clicks Submit, the results open in a new window and that part works correctly.  However, if one was to close that window and enter new information for a parameter and click Submit again, a new window would once again open but have the wrong results.  One could work around the issue by either returning to the sqlReports main menu and running the report again, or removing the Open in New Window option from the report.   sqlReports 5.4.1 has a coding change that fixes the problem and allows one to use the Open in New Window and have the correct results display in the new window without having to return to the main menu before each Submit.

Coding Change

It's recommended that users of sqlReports upgrade to 5.4.1 because the issue could cause bad data to appear on reports with the Open in New Window option checked (a previous blog post covers how to find those reports).  However, if one doesn't want to upgrade, here is how to fix the issue with sqlReports 4 or 5.  The fix involves changing some coding on the params.html page, which resides in the sqlReports4 or sqlReports5 folder in the /admin folder.  If one is also using the teacher version of sqlReports, the fix must also be applied to the params.html page in the sqlReports4 or sqlReports5 folder in the /teachers folder.

View the html and look for the following line toward the top of the page:

var sQuery = document.forms[0].elements['sqlQuery'].value;

and change it to the following instead:

var sQuery = document.forms[0].elements['~(JSFieldParam;[06]ValueT)'].value;

The difference in the code is that the sqlQuery part in single quotes is replaced with the ~(JSFieldParam;[06]ValueT) coding.

Issue with Option A student selection choice

A known issue remains with reports using Option A from the Student Selection tab and the Open in New Window option.  The current selection of students link at the bottom of the report does not update unless one goes back to the sqlReports main menu and runs the report again.  The workaround is to use Option B instead or to not use Open in New Window and Option A on the same report. 

The download counter has been reset for the main download of sqlReports and the Saved Params download.  Archived versions of sqlReports have been removed from the Premium Downloads area to prevent people from installing older versions with the bug.

Thanks to Charles P for notifying me of the issue and helping test the fix!