Examples of Connecting to SSAS via XMLA

All matters relating to OAT

Examples of Connecting to SSAS via XMLA

Postby mark_ellul on Tue Sep 23, 2008 7:21 am

Hi,

I am new to the OpenLink Ajax Toolkit, I was wondering if there are any examples of connecting to SqlServer Analysis Services via the XMLA functionality?

I am trying to connect to my local machine using the code below, in IE it shows nothing wrong neither does it do the alert, and i Firefox 3 it shows a Ajax Error.

PS: I have set up the XMLA over HTTP using IIS (which I am running on port 8181...long story)... using the information provided by http://www.microsoft.com/technet/prodtechnol/sql/2005/httpasws.mspx

Code: Select all
    <script type="text/javascript">
    var featureList = ["xmla"];

    options = new Object();
    options.endpoint = "http://http://localhost:8181/olap/msmdpump.dll";

    OAT.Xmla.connection = new Object();
    OAT.Xmla.connection.options = options;

    var callback = function(data) {
               alert(data); // array of DSNs
               }
    OAT.Xmla.discover(callback);

    </script>


The Firefox AJAX Error is below..

Code: Select all
generic uncaught error = uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIXMLHttpRequest.setRequestHeader]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: http://localhost:8080/javascripts/oat/ajax2.js :: anonymous :: line 282" data: no], url = , line = 0
uncaught exception: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIXMLHttpRequest.setRequestHeader]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: http://localhost:8080/javascripts/oat/ajax2.js :: anonymous :: line 282" data: no]


Am I doing something obviously wrong?

Is my XMLA.connection set correctly?

Any help would be appreciated.

Regards

Mark
mark_ellul
 
Posts: 1
Joined: Tue Sep 23, 2008 7:17 am

Re: Examples of Connecting to SSAS via XMLA

Postby bkutil on Wed Sep 24, 2008 3:32 am

Hi Mark,

These exceptions appear mostly with AJAX errors. From the code you've pasted, the options.endpoint isn't correct (note the double http://).

In case you get such error, more sensible output can be obtained by surrounding the code with try { } catch(e) { console.log(e): } and then inspecting the exception object via firebug. That can help you get a backtrace and the precise line of the error.

Let me know if this helps.
bkutil
 
Posts: 2
Joined: Thu May 01, 2008 3:17 am

Re: Examples of Connecting to SSAS via XMLA

Postby louenlax on Thu Oct 29, 2009 1:53 am

How to use ajax validation for forms in php? I need to know with codes or example how can ajax be used in php for form validations, slide shows etc.
___________________
keyword research ~ keyword tool ~ keyword tracking ~ affiliate elite
louenlax
 
Posts: 1
Joined: Sat Oct 24, 2009 5:52 am


Return to OpenLink Ajax Tookit (OAT)

Who is online

Users browsing this forum: No registered users and 1 guest

cron