Return json content using webservice connection
lunendl Oct 6, 2014 6:30 AMHi Everyone,
I'm new to your product and I'm loving it. However there is one little issue I'm facing which I'm struggling to solve.(It's been a week now) I'm connecting to a webservice with input as JSON and returns JSON content:
Input Parameters query : string(4000) is:
{"queryType":"groupBy","dataSource":"wikipedia","granularity":"minute","dimensions":[ "page" ],"aggregations":[ {"type":"count", "name":"rows"}, {"type":"longSum", "fieldName":"count", "name":"edit_count"}], "filter":{ "type":"selector", "dimension":"namespace", "value":"article" }, "intervals":[ "2014-10-02T10:00/2014-10-03T00" ]}
My SQL Result is:
select * from ( exec "DataProviderView1"."runQueryJson"({"queryType":"groupBy","dataSource":"wikipedia","granularity":"minute","dimensions":[ "page" ],"aggregations":[ {"type":"count", "name":"rows"}, {"type":"longSum", "fieldName":"count", "name":"edit_count"}], "filter":{ "type":"selector", "dimension":"namespace", "value":"article" }, "intervals":[ "2014-10-02T10:00/2014-10-03T00" ]}) ) AS X_X
org.teiid.runtime.client.TeiidClientException: java.lang.RuntimeException: Remote org.teiid.api.exception.query.QueryParserException: TEIID31100 Parsing error: Encountered "exec \"DataProviderView1\".\"runQueryJson\"([*]{[*]\"queryType\":" at line 1, column 57.
Was expecting: "char" | "cast" | "convert" | "any" | "array_agg" | "case" | "exists" | "false" | "hour" | "insert" ...
I have tested my steps by using an existing webservice called "CurrencyConvertor" from http://webservicex.net/CurrencyConvertor.asmx?WSDL and it works without any issues.
My Setup steps are(I have attached the WSDL file):
Teiid Import - "Web Service Source >> Source and View Model (SOAP)"
Connection Profile - File From: http://demo.company.uk.com/company_webservice/DataProvider.asmx?WSDL
- End Point: DataProviderSoap
- Binding Type: SOAP11
Service Mode: PAYLOAD
WSDL Selection Details:
Operation: runQueryJson
binding: DataProviderSoap
port: DataProviderSoap
service: DataProvider
id: {http://demo.intenda.uk.com/fraxses_webservice/}DataProviderSoap.runQueryJson
input message: runQueryJsonSoapIn
output message: runQueryJsonSoapOut
fault names: none
Procedure Definition:
- Request
Body - Schema Contents:
-runQueryJson
-sequence
-query
-string
Element Info:
query
- Response
Body - Schema Contents:
-runQueryJsonResponse
-sequence
-runQueryJsonResult
-string
Column Info:
Root Path - /tns:runQueryJsonResponse
Grid:
Name: runQueryJsonResult, Data Type: string, Path: /tns:runQueryJsonResult
If anyone can help in any way, I would be sooooo grateful.
-
DataProvider.wsdl.zip 1.4 KB