COGNOiSe.com - The IBM Cognos Community

IBM Cognos Analytics Platform => Cognos Analytics => Administration and Security => Topic started by: cognosjon on 13 Aug 2020 10:19:10 AM

Title: REST API connection within R7
Post by: cognosjon on 13 Aug 2020 10:19:10 AM
Hi,
Not sure if this is an issue with how i'm configuring the data server connection or something else so apologies if its in the wrong subject area.

With the new REST API connection within R7 ive been trying to follow the example provided by  Jason Tavoularis on this link. https://community.ibm.com/community/user/businessanalytics/blogs/jason-tavoularis1/2020/07/30/connecting-to-rest-api-data?CommunityKey=6b10df83-0b3c-4f92-8b1f-1fd80d0e7e58&tab=recentcommunityblogsdashboard (https://community.ibm.com/community/user/businessanalytics/blogs/jason-tavoularis1/2020/07/30/connecting-to-rest-api-data?CommunityKey=6b10df83-0b3c-4f92-8b1f-1fd80d0e7e58&tab=recentcommunityblogsdashboard)

I have no issues in creating the data server connection. It tests successfully and if I copy the url into a browser window i can see the data.
What i'm struggling with is how do i then make this data visible within a data module as presently I dont see anything.

Do i need to load the meta data as I would with any other data server connection?

Would anyone be able to point me in the right direction as i've tried with a couple of different api connections and whilst they all test ok when i create the data server connection i dont seem able to then view the data via a data module. I must be missing something.

Any help appreciated
Thanks
Title: Re: REST API connection within R7
Post by: hardstep on 13 Aug 2020 12:50:12 PM
Have you tried refreshing the metadata in the data source connection, you should be able to browse the data schema in there.
That might explain why you see nothing in the data module.
Title: Re: REST API connection within R7
Post by: cognosjon on 13 Aug 2020 02:15:54 PM
Hi,
yes reviewed the meta data and have also allowed it to refresh all of the entries. The schema entry detailed as Autorest then only provides access to a configuration table.

This is why i'm convinced I'm missing a trick with the config of the data server.
Title: Re: REST API connection within R7
Post by: hardstep on 14 Aug 2020 03:51:22 AM
Hi @cognosjon
I tried it just now with the following connection string : jdbc:ibmcognos:autorest:Sample='https://statsapi.web.nhl.com/api/v1/teams';
and it works fine for me. The metadata refresh brought through 3 tables in the AUTOREST schema and I can access and browse the TEAMS table in my data module.
Maybe post a picture of you connection settings and I can help some more.
Regards
Nick
Title: Re: REST API connection within R7
Post by: cognosjon on 14 Aug 2020 04:59:24 AM
Thanks hardstep,

Thats the exact same connection string i have been using which is even more frustrating.

I've tried it again on a different machine and its worked straight away. I can see the tables under Autorest which is very odd as the other machine refuses to display......

Thanks for help, at least I can have a play now and then I suppose I'll go and have a look at what this other machine thinks its doing.