I have developed a CakePHP application that does basic CRUD on a series of tables I’ve created. The CakePHP app seems to be working very, VERY well and I would really like to use it more in the long run.
That said, my needs involve using SQL Server Reporting Services to run reports against the data. Microsoft has released a PHP SDK to connect to SSRS and display reports.
I’m not positive about the best practices way of setting up the MVC structure to accomplish what I want.
I can envision setting up a table that contains the list of reports and another table that contains a list of required / optional parameters and generating a view/controller for that model that would present the user with a list of reports that they could run, then creating a view for reportexecute(or somesuch) that would take the user’s input then call SSRS using the SDK I’ve referenced above.
Is this a common way to solve this problem? Is there a better way that I’m missing? I don’t want to muck up my lovely MVC app by hacking my way through this part!
Thank you in advance!
You could just consume the SSRS web services which provide all the reporting meta information as a normal SOAP XML response. Using the XML you can then do whatever you like without any constraints.
Here’s an example of consuming the web service in an ASP .Net application which you should be able to easily adapt to your PHP requirements.