- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
How to create phoenix table using existing hbase table ??
- Labels:
-
Apache HBase
-
Apache Phoenix
Created ‎03-08-2016 10:45 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
my use case i need to create phoenix table by using existing hbase table. I have got only one way to map hbase table i,e creating view table. is there any other way to create phoenix table by using existing hbase table ??
Created ‎03-27-2016 11:09 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Lets say you have an existing HBase table called "transactions", column family called "transactions" that has a column called transactionId. You can map that table to a Phoenix view with: CREATE VIEW "TransactionHistory" (k VARCHAR primary key, "Transactions"."transactionId" VARCHAR);. Now you should be able to Select "transactionId" from "Transactions". You can use ALTER VIEW to add additional columns from he HBASE table after that.
Created ‎03-08-2016 10:45 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You may refer below section. https://phoenix.apache.org/faq.html#How_I_map_Phoenix_table_to_an_existing_HBase_table
Created ‎03-27-2016 11:09 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Lets say you have an existing HBase table called "transactions", column family called "transactions" that has a column called transactionId. You can map that table to a Phoenix view with: CREATE VIEW "TransactionHistory" (k VARCHAR primary key, "Transactions"."transactionId" VARCHAR);. Now you should be able to Select "transactionId" from "Transactions". You can use ALTER VIEW to add additional columns from he HBASE table after that.
Created ‎06-22-2017 04:03 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
CREATE TABLE table2 LIKE table1;
INSERT INTO table2 SELECT * FROM table1;
These are sql queries which can be used but not working with base..
By d way nice question.
I am also trying for it.
