You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@phoenix.apache.org by "Karthik Palanisamy (JIRA)" <ji...@apache.org> on 2019/06/05 21:31:00 UTC

[jira] [Commented] (PHOENIX-3541) Bulk Data Loading - Can't use table name by small letter

    [ https://issues.apache.org/jira/browse/PHOENIX-3541?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16857051#comment-16857051 ] 

Karthik Palanisamy commented on PHOENIX-3541:
---------------------------------------------

This JIRA is inactive long. Thank [~kalyanhadoop] for your initial patch.

w/ initial patch we still face bulkload failure.  

{code}

java.lang.IllegalArgumentException: Table S."t" not found

at org.apache.phoenix.util.SchemaUtil.generateColumnInfo(SchemaUtil.java:956)
 at org.apache.phoenix.mapreduce.AbstractBulkLoadTool.buildImportColumns(AbstractBulkLoadTool.java:378)
 at org.apache.phoenix.mapreduce.AbstractBulkLoadTool.loadData(AbstractBulkLoadTool.java:211)
 at org.apache.phoenix.mapreduce.AbstractBulkLoadTool.run(AbstractBulkLoadTool.java:180)
 at org.apache.phoenix.end2end.CsvBulkLoadToolIT.testBasicImport1(CsvBulkLoadToolIT.java:467)
..

{code}

I think Apache commons-cli.version is changed to 1.4 and this incorrectly interprete QUOTES, is caused bulkload failure. Similar one, [CLI-275|https://issues.apache.org/jira/browse/CLI-275]
\"\"t\"\"  -> ""t"" (Incorrect) 
"t"  -> t    (this is correct)
\"t\" -> t    (Incorrect)
'"t"'  -> t   (single quote - double quote - tilde - double quote - single quote => INcorrect)
"'"t"'" -> 't' (double - single - double - tilde - double - single - double => correct - surprisingly to me, echo produces the same result.)
"'t'" -> 't'  (double-single-tilde-single-double) -> Correct)
'""' -> empty string (single-double-double-single) -> INcorrect)
"''" -> '' (double-single-single-double    ->   single-single   -> Correct)
"\"t\"" -> t (double - esc double - tilde - esc double - double -> INcorrect).
"\\"t\\"" -> \t\ (double - esc backslash - double - tilde - esc backslash - double -> correct)
 

Posted new patch that handleds dual double quote from input tableName/schemaName.

\"\"t\"\"   ->  ""t""   (CLI)

""t""   -> "t" -> t (Bulkload)

Cc: [~ankit.jhil]

> Bulk Data Loading - Can't use table name by small letter 
> ---------------------------------------------------------
>
>                 Key: PHOENIX-3541
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-3541
>             Project: Phoenix
>          Issue Type: Bug
>    Affects Versions: 4.8.0
>            Reporter: Beomjun Kim
>            Assignee: Kalyan
>            Priority: Critical
>         Attachments: PHOENIX-3541.master.v1.patch, PHOENIX-3541.patch
>
>
> i have existing Phoenix table abc
> i wanna Bulk Data Loading via MapReduce  
> And then used the following command to load the csv file
> hadoop jar /root/Phoenix/apache-phoenix-4.8.0-HBase-0.98-bin/phoenix-4.8.0-HBase-0.98-client.jar org.apache.phoenix.mapreduce.CsvBulkLoadTool   --t  abc --input /example.csv
> but, it does not seem to find the table abc
> Exception in thread "main" java.lang.IllegalArgumentException: Table ABC not found
> i try change command  table name  --t 'abc' and --t "abc"
> but it doesn't work  
> how can i use table name small letter ??
> And also, i found  same case  
> http://apache-phoenix-user-list.1124778.n5.nabble.com/Load-into-Phoenix-table-via-CsvBulkLoadTool-cannot-find-table-and-fails-td2792.html



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)