问题
How to fetch Physical SQL Query from a Semantic Query in RDL file?
We have some following steps to go ahead while extracting the Semantic Query from RDL
- Extract the Semantic Query from RDL file
- Validate against the Semantic Model XSD
- Parse and Transfrom Semantic Query into a structure where we will be able to generate Physical SQL from
- Execute the conversion process to get physical query
We accomplished step 1, We were able to Extract the semantic query from RDL and store it in XML
Question 1:
For step 2, Validating against the XSD. XSD path is http://schemas.microsoft.com/sqlserver/2004/10/semanticmodeling/SemanticModeling.xsd and our XML is extracted from RDL. The Semantic Model XSD mentioned above has some import namespace to DataSourceView.XSD. Can anyone suggest how and where can I get DataSourceView.XSD?
Question 2:
For Parse and Transform the Semantic Query, do we need to create an XML parser in C# or does any API which can perform this.
We can't Run the RDL file against Reporting model, because our requirement is to get the Physical SQL not the Dataset.
回答1:
I haven't found a way to extract the SQL or convert the semantic query to SQL directly from an RDL file that contains a report model reference.
However, the SQL is available in the Report Server log file after the report is generated.
来源:https://stackoverflow.com/questions/8485871/how-to-fetch-physical-sql-query-from-a-semantic-query-in-rdl-file