Products | Versions |
---|---|
Spotfire Statistica | 13.1 and higher |
1. In WebStatistica, first create a new spreadsheet (XXX.STA) by clicking on "FIle" | "Create Dataset".
Give a name and set various options for the new spreadsheet, e.g. Number of variables, Number of Cases, e.t.c. Click on the question mark "?" on the top right corner of the dialog for more explanations on the parameters and options available.
2. Click OK. A new WebStatistica webpage with Spreadsheet Editor will pop up. User can manually key in data in the Spreadsheet Editor and click on "Upload" to save the changes. User can also leave the spreadsheet blank at this stage if user wants to query data table from Database connections. (Note that this Spreadsheet Editor requires appropriate version of Java to open: See this KB for Java required)
The spreadsheet created in this step will be listed under "My Directory" folder when you click on "File" | "Open Dataset" to select the Active Data Source.
3. The newly created spreadsheet from step 2 is automatically set as Active Data Source. If keen to switch to other spreadsheets created, click on "File" | "Open Dataset", expand the folders, select the spreadsheet of interest, click OK to set it as Active Data Source for downstream analysis.
Here the option "WebStatistica Spreadsheet Editor" is for user to open and update the spreadsheet with Spreadsheet Editor.
4. Click on "Create/Edit Query" under "Database Queries" section, create a new query for the active spreadsheet.
Name the query, provide the Database "Connection String" and specify "Maximum Rows".
The "Connection String" could be copied from the "connection string" for "Database Connection" in Enterprise Manager. Or alternatively user can go to Statistica "File | External Data | Create Query" to build an OLE DB connection to the database of interest. Note that the database connection string from Enterprise Manager masks the password with *****, user need to replace it with the real actual password when pasting to the WebStatistica query dialog.
5. Click OK. The WebStatistica Query Editor webpage opens up. The data tables in the connected database are listed on the left panel. Select the data table of interest, go to "Table" in the menu, click on "Add" to add the table of interest to the dialog on the right panel.
(Note that since this operation is Java dependent, the drag and drop that can be used in Statistica will not work here).
6. In the Query Editor dialog on the right panel, Select the table fields/variables that need to be retrieved and then click on the green triangle button (highlighted in above figure). The query is now saved.
7. The saved query could then be executed by clicking on "Run Saved Query" in WebStatistica.
8. You will get a message indicating the query has run and that you need reload the file. Click OK
On the spreadsheet, click on "File | Reload Current Spreadsheet". The retrieved dataset is displayed and now available for further analysis via WebStatistica.
Additional Explanations:
Connection String: Specify here the ODBC connection string for accessing the external (remote) database. Contact your database and/or WebSTATISTICA administrator for details.
Maximum Rows: Specify here an optional maximum number of rows (records) that are to be retrieved by the query. All "requests" by subsequent analyses (on these data) for the number of cases in the data set will return this number. This allows you to specify an upper limit of records in case your query returns more data than expected. If there are more cases than this, they will not be returned. With this option, you can "fine-tune" the performance (speed) of subsequent data analyses.