cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Can't get anything out of my MII/OData request

Former Member
0 Likes
1,625

Hello everyone,

I've created a "FixedQueryWithOutpu" with a simple SELECT query for test reasons. I want to get a valid OData request out of MII.

The query is stored in the project examples, in the folder "Tests", containing the same folder "Tests" and finally in the folder "Reports".


Examples/Tests/Tests/Reports/TestData

I've used this path to request the OData:

http://hostname:10000/XMII/IlluminatorOData?QueryTemplate=Examples%2FTests%2FTests%2FReports%2FTestD...

However, I get this response (what isn't too bad actually 😞


This XML file does not appear to have any style information associated with it. The document tree is shown below.

<service xmlns="http://www.w3.org/2007/app" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:app="http://www.w3.org/2007/app" xml:base="http://hostname:10000/XMII/IlluminatorOData/">

  <workspace>

    <atom:title>Default</atom:title>

      <collection href="Rowsets">

        <atom:title>Rowsets</atom:title>

      </collection>

      <collection href="Column">

        <atom:title>Column</atom:title>

      </collection>

      <collection href="Row">

        <atom:title>Row</atom:title>

      </collection>

      <collection href="Rowset">

        <atom:title>Rowset</atom:title>

      </collection>

      <collection href="Messages">

        <atom:title>Messages</atom:title>

      </collection>

  </workspace>

</service>

Following this post, I've use this path to gather information from my request (rowsets or something):


<protocol>:<server>:<port>/XMII/IlluminatorOData/Rowset(‘<QueryTemplateName>’)/Rowset

http://myServer:10000/XMII/IlluminatorOData/Rowsets(‘MyProject/MyFolder/MyQuery’)/Rowset

In reality:

http://hostname:10000/XMII/IlluminatorOData/Rowsets(‘Examples/Tests/Tests/Reports/TestData’)/Rowset

However, what I've got is just an error message of the server:


This XML file does not appear to have any style information associated with it. The document tree is shown below.

  <error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">

    <code>ServerErrorException</code>

    <message lang="en-US">Internal Server Error</message>

  </error>

What am I doing wrong? I'm stuck with this OData topic for weeks now. I really don't get why it's that hard to get data out of this "panacea" of backend service.
A colleague is working on OData with Olingo and he doesn't really seem to be convinced that there may exist a OData request without a valid ".svc" url. Why don't we have such?

Many thanks and kind regards,

(a slightly bugged) Kai

Accepted Solutions (1)

Accepted Solutions (1)

former_member193328
Active Participant
0 Likes

Hi Kai

What is you MII and NW Versions?

regards

Partha

Former Member
0 Likes

Hi Partha,

MII:

14.0 SP5 Patch 12 (01.10.2014)

NW:

v.7.31

Thanks and regards,

Kai

Edit:

We've upgraded to the latest version (SP6) yesterday.

Still not working 😕

Former Member
0 Likes

Do we have to upgrade our NW to 7.4?

Former Member
0 Likes

Hello Kai,

when I remember correct, oData in MII only support the Mode Query (no FixedQuery or

FixedQueryWithOutput). Please try with Mode Query in your SQLQuery.

BR

Pedro

former_member193328
Active Participant
0 Likes

Hi Kai

There is no need for that. Ideally even NW 731 should have the same ODATA features. Can you check if the ODATA SCA is deployed on your NW server? From the error message above it seems it is there but to double check.

Also in line with Pedro's comment above I checked the help for ODATA. You can find it here. http://help.sap.com/saphelp_mii140/helpdata/en/44/2e1d2d42994aef85ef91e58db8c7c9/frameset.htm

MII ODATA Does support FixedQueryWithOutput but only with HTTP method set as POST and not GET. You may try this as well. All other modes are supported both with GET as well as POST.

Regards

Partha

Former Member
0 Likes

Hi Partha,

I have check again and I am correct. The help is wrong. I open last year a ticket and they answer that

only Mode Query is supported. Please take a look into the OSS 217133. They also told me that the

documentation will be changed.

BR

Pedro

former_member193328
Active Participant
0 Likes

Hi Pedro

Sorry I was believing the documentation but as you say this is not the case then. I hope documentation is updated soon

Regards

Partha

Former Member
0 Likes

Partha,

it is around 1 year ago, my OSS! Maybe you can remind internal. OSS is closed

and I have no chance to update it.

BR

Pedro

Former Member
0 Likes

Hi Pedro,

thanks for your input!

Okay, what I've done now is:

- Created a simple Query (project "Default", name "ODa")

- Tested the Query (it works =))

- Used the URL http://hostname:10000/XMII/IlluminatorOData?QueryTemplate=Default%2FODa

- Got the Result:


This XML file does not appear to have any style information associated with it. The document tree is shown below.

<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">

     <code>ServerErrorException</code>

     <message lang="en-US">Internal Server Error</message>

</error>

Former Member
0 Likes

Hi Partha,

thanks for your reply.

The following software component is deployed:

VendorNameVersion
sap.comODATA-CXF-EXT1000.7.31.13.0.20140828180700

Is this okay?

RiaNinan
Product and Topic Expert
Product and Topic Expert
0 Likes

Hi Kai,

The component information looks fine.

You could try the below URL to get the query data for your QueryTemplate (Default/ODa)

     http://<host>:<port>/XMII/IlluminatorOData/Rowsets('Default/ODa')/Rowset              or

     http://<host>: <port>/XMII/IlluminatorOData/Rowset(QueryTemplate='Default/ODa',RowsetId=1)/Row

Hope this helps!

Thanks and Best Regards,

Ria

Former Member
0 Likes

Hi Ria,

as simple as that. You, Ria, just made my day, week and month. Thank you so much!

I've used the first URL given to create a heck of a XML document containing the correct data.

Thanks and regards,

Kai

Answers (2)

Answers (2)

Former Member
0 Likes

Anybody who has a suggestion?

What may help is someone who has a case study of his very own implementation of the MII/OData thing.

swaroop_anasane
Active Contributor
0 Likes

hi kai,

is it mandate to use odata?

-Swaroop

Former Member
0 Likes

Hi Swaroop,

no, but we wanted to switch completely to OData in the near future. That's why I want to make my code as "OData near" as possible. I wanna be able to use my UI5 application even with Olingo as a backend service.

Thanks and regards,

Kai

Former Member
0 Likes

Hi Kai,

Having ".svc" in URL is a OData Service standard for .Net.

However, the URL specified by you points to the Service document URL as there is no namespace provided to it.

http://hostname:10000/XMII/IlluminatorOData/QueryTemplate?QueryTemplate=Examples%2FTests%2FTests%2FReports%2FTestData

The above mentioned URL should give you your query data.

Thanks and Regards,
Anuvrat

Former Member
0 Likes

Hi Anuvrat,

thanks for your reply.

I've use your URL and now I get:


This XML file does not appear to have any style information associated with it. The document tree is shown below.

<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">

     <code>NotFoundException</code>

     <message lang="en-US">EdmEntitySet QueryTemplate is not found</message>

</error>

Do I have to replace QueryTemplate with anyhting else?

Former Member
0 Likes

Hi Kai,

Can you please try to run the URL given below followed by the URL that I provided earlier:

http://hostname:10000/XMII/IlluminatorOData/$metadata

Regards,

Anuvrat

Former Member
0 Likes

Hi Anuvrat,

thanks for your reply.

I've used this link

http://hostname:10000/XMII/IlluminatorOData/$metadata/QueryTemplate?QueryTemplate=Examples%2FTests%2...

To generate this output



This XML file does not appear to have any style information associated with it. The document tree is shown below.

<error xmlns="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata">
<code>NotImplementedException</code>
     <message lang="en-US">

     Queryable metadata not implemented by this producer

     </message>

</error>

Former Member
0 Likes

Hi Anuvrat,

we are running on SP05/12 at the moment.
Do we have to upgrade to SP06?

Could this be the problem?

Thanks and regards,

Kai