Re-posting this message to the user list since I received no reply on the dev list.

I would appreciate your advice about how to INSERT data into a table with a BINARY-typed partition key.

It seems that hexit strings can be INSERTed into columns which aren't partition keys. The hexit strings look fine when you query the table. However, hexit strings come back as gibberish after being used as partition key values. The following Hive QL script shows this behavior:

USE rick;

DROP TABLE foo;

CREATE TABLE foo (a BINARY) PARTITIONED BY (b BINARY);

INSERT INTO foo PARTITION (b='FEED') VALUES ('FEED');

SELECT * FROM foo;


The result of the terminal SELECT is:

| foo.a | foo.b       |

|-------|-------------|

| FEED  | [B@1b881a6f |


Thanks,
-Rick


Reply via email to