Please send the full exception trace logged in the console.

Thanks,
Sinthuja.

On Tue, Jan 6, 2015 at 3:42 PM, Chamin Nalinda <[email protected]> wrote:

> Hi all,
>
> I get following error while trying to execute hive query below.
>
> error
>
> *ERROR: *Error while executing Hive script.Query returned non-zero code:
> 9, cause: FAILED: Execution Error, return code 1 from
> org.apache.hadoop.hive.ql.exec.DDLTask
>
>
> =======================
>
> Hive query
>
> DROP TABLE AuditBase;
> DROP TABLE AuthAdminLogs;
>
> CREATE EXTERNAL TABLE IF NOT EXISTS AuditBase
> (mesid STRING, timestampstr BIGINT, payload_message STRING,
> payload_priority STRING)
> STORED BY 'org.apache.hadoop.hive.cassandra.CassandraStorageHandler'
> WITH SERDEPROPERTIES ("wso2.carbon.datasource.name" =
> "WSO2BAM_CASSANDRA_DATASOURCE",
> "cassandra.cf.name" = "log_0_IS_2014_10_30",
> "cassandra.columns.mapping" = ":key, Timestamp,
> payload_message,payload_priority");
>
> CREATE EXTERNAL TABLE IF NOT EXISTS AuthAdminLogs(messageid STRING,
> timestampstr STRING, username STRING, remotehost STRING, response STRING)
> STORED BY
> 'org.wso2.carbon.hadoop.hive.jdbc.storage.JDBCStorageHandler'
> TBLPROPERTIES (
> 'wso2.carbon.datasource.name'='WSO2BAM_MYSQL_DATASOURCE',
> 'hive.jdbc.update.on.duplicate' = 'true' ,
> 'hive.jdbc.primary.key.fields' = 'messageid' ,
> 'hive.jdbc.table.create.query' =
> 'CREATE TABLE AuthAdminLoginDetails (messageid VARCHAR(100) NOT NULL
> PRIMARY KEY, Timestampstr VARCHAR(100), UserName VARCHAR(100)
> , RemoteHost VARCHAR(20), Response VARCHAR(20))');
>
> insert overwrite table AuthAdminLogs
> select mesid, from_unixtime(cast(timestampstr/1000 as BIGINT), 'yyyy-MM-dd
> HH:mm:ss'),
> split(payload_message,"#")[1],split(payload_message,"#")[2],split(payload_message,"#")[4]
> from AuditBase where split(payload_message,"#")[0]="AuthenticationAdmin";
>
>
>
>
>
>
> --
> *Chamin Nalinda*
>
> Intern - Engineering
> WSO2 Inc. http://www.wso2.com
> lean.enterprise.middleware
>
> Mobile: (+94) 77 241 66 04
> Linkedin: https://www.linkedin.com/in/chaminnalinda
> Web: http://www.ckreativity.com
> Blog: http://techspiro.blogspot.com/
>
>
> _______________________________________________
> Dev mailing list
> [email protected]
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Sinthuja Rajendran*
Senior Software Engineer <http://wso2.com/>
WSO2, Inc.:http://wso2.com

Blog: http://sinthu-rajan.blogspot.com/
Mobile: +94774273955
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to