MicroStrategy ONE
Quick Start Guide
To help you get started creating custom data connectors, we have provided a working sample that you can download and play with. By design, it is a simple connector that uses a CSV file as its data source. You can extrapolate from this simple code to build a custom connector of your own.
To start using the sample in your MicroStrategy environment, follow the steps below.
- Set up the sample.
Download the zip file for the sample data connector, DataConnectorSample.zip.
If you created a custom data connector with a version of the product prior to 11.0, you must upgrade your MicroStrategy product and replace mstrgdc-1.0.js with mstrgdc-2.0.js to take advantage of new features, such as table-level settings for multiple tables. In releases prior to 11.0, if multiple tables were imported in one connection, they all had to share the same settings. Simply download mstrgdc_20js.zip, extract the latest version of the mstrgdc-2.0.js Javascript file, and use it to replace the existing Javascript file in your data connector.
- Extract the contents. The following files are included in the DataConnectorSample folder:
- index.html
- mstrgdc-2.0.js
- RawDataFiles.js
- DataConnectorSampleIcon.png
- DATA_IMPORT_CSV.csv
Copy the DataConnectorSample folder to the MicroStrategy root folder on your Tomcat web server.
In these instructions, you place the sample folder in the root directory of your web server, but you can change that to any location in the MicroStrategy Web directory.
For this sample, the sample files have to be in the same folder. However, this is not a requirement. You could change the paths in the HTML and Javascript files to allow the sample files to be in different directories.
-
Register the sample connector.
Use the steps outlined in Registering a Data Connector. When you configure the connector, use the following values:
Connector name Enter "Sample Connector". Connector URL Enter "http://YourWebServer/MicroStrategy/DataConnectorSample/index.html" Connector description Enter "Simple connector that uses a CSV data file". Connector introduction page This is optional and is not used in this sample. It can be used to enter a URL to a page that provides introductory information about the connector. Connector icon Navigate to DataConnectorSampleIcon.png in the DataConnectorSample folder. Credential type This information is not currently used. - Try out the sample connector.
- Open MicroStrategy Web or Desktop.
- Navigate to Create -> New Dashboard.
- Click Add External Data.
On the Connect to Your Data page, scroll down to the new data connector you added.
Click the icon for your new connector, and the HTML page in the sample opens.
- In the textbox on the screen, enter the name of the CSV data file included in the sample (DATA_IMPORT_CSV.csv) and click Submit.
It says "Fetching Cube information" and then redirects you back to MicroStrategy Web to complete the data import process.