[ 
https://issues.apache.org/jira/browse/HBASE-828?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12623435#action_12623435
 ] 

Ryan Smith commented on HBASE-828:
----------------------------------

Hi Izaak,

Thanks for responding.  then the trouble could be in the way im making the 
table.
If you could, please test creating the table using HTableDescriptor.

                log.info("creating table in HBase: tableA");
                HTableDescriptor desc = new HTableDescriptor("tableA");

                desc.addFamily(new HColumnDescriptor("label:"));
                HBaseAdmin admin = new HBaseAdmin(hbaseConf);
                if (!admin.tableExists(new Text("tableA"))) {
                        try {
                                admin.disableTable(desc.getName());
                                admin.deleteTable(desc.getName());
                        } catch (TableNotFoundException te) {
                                log.info("no existing table was found to 
delete.");
                        }
                        admin.createTable(desc);
                        for (HTableDescriptor table : admin.listTables()) {
                                log.info("found table: " + table.getName());
                        }
                }

> HBaseAdmin.tableExists(new Text("TestTable5")) returns false when table 
> actually exists.
> ----------------------------------------------------------------------------------------
>
>                 Key: HBASE-828
>                 URL: https://issues.apache.org/jira/browse/HBASE-828
>             Project: Hadoop HBase
>          Issue Type: Bug
>          Components: util
>    Affects Versions: 0.2.0
>            Reporter: Ryan Smith
>            Priority: Minor
>             Fix For: 0.3.0
>
>
> Process:
> One the 1st MR job, i use tableExists( new Text("TestTable5")) & tableCreate 
> to create the table.
> On the 2nd MR job, I call tableExists(new Text("TestTable5")), which returns 
> false, then i call disableTable, deleteTable, and finally createTable.
> Workaround for now is to avoid using Text.   tableExists(byte[]) works when i 
> tested it.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to