I'm getting a Table Not Found error while running a select query on spark console of wso2das. I've kept all the default configurations intact after the installation. I'm unable to fetch the data from the event stream even when it's been shown under table dropdown of data explorer.
Asked
Active
Viewed 156 times
0
-
2explain more in detail what you've done so far http://stackoverflow.com/help/how-to-ask – bibi Feb 03 '16 at 09:15
-
After installing the product, using a proxy service and event sink in wso2esb, I was able to get the message in the event stream of wso2das. But when I'm trying to fetch the data using spark query in console I got table not found error. – Alok Shukla Feb 03 '16 at 09:27
1 Answers
0
Initially when the data is moved into the wso2das, it would be persisted in the data store you mention.
But, these are not the tables that are created in spark. You need to write a spark query to create a temporary table in spark which would reference the table you have persisted.
For example,
If your stream is,
{
"name": "sample",
"version": "1.0.0",
"nickName": "",
"description": "",
"payloadData": [
{
"name": "ID",
"type": "INT"
},
{
"name": "NAME",
"type": "STRING"
}
]
}
you need to write the following spark query in the spark console,
CREATE TEMPORARY TABLE sample_temp USING CarbonAnalytics OPTIONS (tableName "sample", schema "ID INT, NAME STRING");
after executing the above script,try the following,
select * from sample_temp;
This should fetch the data you have pushed into WSO2DAS.
Happy learning!! :)

Aswin
- 71
- 1
- 1
- 7