Are there any documents to help me understand the meaning and usage of
"input.regex"?

I create table as your introduction. And "select * from table1" returns the
right answer.
However, "select table1.str1 from table1" gains the following exception.

Total MapReduce jobs = 1
Launching Job 1 out of 1
Number of reduce tasks is set to 0 since there's no reduce operator
Starting Job = job_201104251139_2123, Tracking URL =
http://hadoop-12.apexlab.org:50030/jobdetails.jsp?jobid=job_201104251139_2123
Kill Command = /usr/lib/hadoop/bin/hadoop job
-Dmapred.job.tracker=hadoop-12:9001 -kill job_201104251139_2123
2011-05-27 20:04:41,618 Stage-1 map = 0%,  reduce = 0%
2011-05-27 20:05:05,413 Stage-1 map = 100%,  reduce = 100%
Ended Job = job_201104251139_2123 with errors
FAILED: Execution Error, return code 2 from
org.apache.hadoop.hive.ql.exec.MapRedTask

Can you help me? thanks.



在 2011年5月25日 下午9:57,valentina kroshilina <kroshil...@gmail.com>写道:

> you can use something like this:
>
> CREATE EXTERNAL TABLE IF NOT EXISTS table1 (
>    str1 int,
>    str2 int,
>    str3 int
> )
> ROW FORMAT SERDE 'org.apache.hadoop.hive.contrib.serde2.RegexSerDe'
> With SERDEPROPERTIES (
> "input.regex"="(\\d+)&&&&(\\d+)&&&&(\\d+)"
> )
> LOCATION '/path1;
>
>
> 2011/5/25 jinhang du <dujinh...@gmail.com>
>
>> Hi all,
>>
>> I want to custom the delimiter of the table in a row.
>> Like my data format is '1&&&&2&&&&4‘, and how could I create a table (int,
>> int, int)
>>
>> Thanks.
>>
>> --
>> dujinhang
>>
>
>
>
> --
> valentina kroshilina
>



-- 
dujinhang

Reply via email to