Add a Metadata Data Source
You must have a report file open in order to proceed, and your data source must be accessible before you can connect to it in Report Designer.
Follow this procedure to add a Metadata data source in Report Designer.
- Select the Data tab in the upper right pane. By default, Report Designer starts in the Structure tab, which shares a pane with Data.
- Click the yellow cylinder icon in the upper left part of the Data pane, or right-click Data Sets. A drop-down menu with a list of supported data source types will appear.
- Select Metadata from the drop-down menu. The Metadata Data Source Editor window will appear.
- Click Browse, navigate to your XMI metadata definition file, then click Open.
- Click the round green + icon to add a query, then type in a name for the new query in the Query Name field.
- Type in the name of the solution directory this metadata file pertains to into the Domain Id field. If this XMI file was created with Pentaho Metadata Editor, then the domain ID has to be the root directory for this solution -- the directory one level above pentaho-solutions, typically. If you created this XMI with Pentaho Data Integration, then the domain ID must be set to the full solution path to the XMI, which would be something like this: example-solution/resources/metadata/mymeta.xmi. If the domain ID is not properly defined, you will be able to preview the report, but you will not be able to publish it to the Pentaho Server.
- Click the pencil icon on the right above the Query field to start Metadata Query Editor, or type in your query directly into the Query field. See Create Queries With Metadata Query Editor for more details on Metadata Query Editor. You can also design a dynamic query via a script; see Dynamic Query Scripting.
- Click OK when your query is complete.