Skip to main content
Previous sectionNext section

DeepSeeResultSet

Enables you to work with the results of a DeepSee query.

Where This Object Is Available

This object is available in client-side JavaScript code, if that code includes DeepSee.js. See “Introduction to DeepSee.js.”

Creating This Object

To create a result set, call the getCurrentData() method of the data controller object.

Or use code like the following:

var resultset = new DeepSeeResultSet(connection,widget,wait,timeout);
Copy code to clipboard

Where:

  • connection — Is a DeepSee data connector object.

  • widget — Specifies the id of the HTML element on the page that will use the data controller.

  • wait — Boolean. If this parameter is false, the server should respond immediately. If this parameter is true, the server should not respond until the query has completed or timed out.

  • timeout — Specifies how long (in seconds) the server should wait before returning final but incomplete query results.

Properties of This Object

The DeepSee result set object provides the following properties:

  • connection — Is a DeepSee data connector object.

  • widget — Specifies the id of the HTML element on the page that will use the data controller.

  • wait — Boolean. If this property is false, the server should respond immediately. If this property is true, the server should not respond until the query has completed or timed out.

  • timeout — Specifies how long (in seconds) the server should wait before returning final but incomplete query results.

  • data — Contains the query results.

  • pollInterval — Specifies how long (in milliseconds) to wait before asking the server for updates to pending results. The default is 1000.

Methods of This Object

The DeepSee result set object provides the following JavaScript methods:

getColumnCount()
getColumnCount()
Copy code to clipboard

Returns the number of columns in the result set.

getCubeName()
getCubeName()
Copy code to clipboard

Returns the name of the cube currently in use.

getErrorMessage()
getErrorMessage()
Copy code to clipboard

This method returns the text of the error message contained in the response object, if any.

getOrdinalLabel()
getOrdinalLabel(axis, position)
Copy code to clipboard

Where:

  • axis is the number of the axis whose labels you want to obtain. Specify 1 for column or 2 for rows.

  • position is the position on that axis whose labels you want to obtain. Specify 1 for the first position on the axis.

Returns an array of strings, corresponding to the labels at the given position on the given axis.

getOrdinalValue()
getOrdinalValue(rowNo,colNo,formatted)
Copy code to clipboard

Where:

  • rowNo is the row number (1–based)

  • colNo is the column number (1–based)

Returns the value in the given cell.

getQueryStatus()
getQueryStatus()
Copy code to clipboard

Returns a numeric value indicating whether the query has completed. This number is 100 if the query has completed. Otherwise, this number is less than 100.

getRowCount()
getRowCount()
Copy code to clipboard

Returns the number of rows in the result set.

isError()
isError()
Copy code to clipboard

This method returns true if the response object indicates that an error occurred. Returns false otherwise.

runMDXQuery()
runMDXQuery(mdx,finalCallback,pendingCallback,filters)
Copy code to clipboard

Where:

  • mdx is an MDX SELECT query.

  • finalCallback is the name of a callback function on this page.

  • pendingCallback (optional) is the name of another callback function on this page.

  • filters specifies additional filters to apply to the query.

This method executes the given MDX query. When the query is pending or completed, DeepSee invokes the given callback functions.

This method has no return value.

runMDXDrillQuery()
runMDXDrillQuery(mdx,finalCallback,pendingCallback,listing,fieldList,filters)
Copy code to clipboard

Where:

  • mdx is an MDX SELECT query.

  • finalCallback is the name of a callback function on this page.

  • pendingCallback (optional) is the name of another callback function on this page.

  • listing is the name of a detail listing.

  • fieldList specifies a list of listing fields. Specify either listing or fieldList.

  • filters specifies additional filters to apply to the query.

This method executes the given drillthrough query. When the query is pending or completed, DeepSee invokes the given callback functions.

This method has no return value.

runPivot()
runPivot(pivot,finalCallback,pendingCallback,filters)
Copy code to clipboard

Where:

  • pivot is the logical name of pivot table.

  • finalCallback is the name of a callback function on this page.

  • pendingCallback (optional) is the name of another callback function on this page.

  • filters specifies additional filters to apply to the query.

This method executes the MDX query defined by the given pivot table. When the query is pending or completed, DeepSee invokes the given callback functions.

This method has no return value.