Yugabyte-db: [YSQL] TablePlus unable to load tables without primary key

Created on 25 Apr 2019  路  5Comments  路  Source: yugabyte/yugabyte-db

For tables that don't have a primary key, TablePlus is not able to load the table. Error displayed is ERROR: System column with id -1 is not supported yet

areysql help wanted

Most helpful comment

Thank you for your clarification.
I can update the PG driver to support YugaByte easily if the select version(); return the driver name.
For example:
In PostgreSQL: select version() returns PostgreSQL 11.0;
it would be great if YugaByte returns YugaByte _version_number; So I can change the query based on that information.

All 5 comments

In postgres log:

2019-04-24 17:30:52.089 PDT [95281] ERROR:  System column with id -1 is not supported yet
2019-04-24 17:30:52.089 PDT [95281] STATEMENT:  SELECT "ctid",* FROM "public"."bar" LIMIT 300 OFFSET 0;
2019-04-24 17:32:16.306 PDT [95281] ERROR:  System column with id -1 is not supported yet
2019-04-24 17:32:16.306 PDT [95281] STATEMENT:  SELECT "ctid",* FROM "public"."nopk" LIMIT 300 OFFSET 0;

Hey @ndeodhar I'm the author of TablePlus. Could you please show me the title of the connection?
Screen Shot 2019-07-15 at 8 28 17 AM
Does it show YugaByte or something? TablePlus uses ctid in PostgreSQL to update the row, but YugaByte doesn't support it.

Hi @huyphams, TablePlus shows PostgreSQL title:
image

This is because we use PostgreSQL datatype while connecting to YB database. While we are compatible with Postgres, we have made changes to Postgres internals for YB. One example of this is changing ctid to a more YB specific ybctid.

We'd love to explore the possibility of building a custom integration for YugaByte with TablePlus. Let us know your thoughts.
cc: @schoudhury

Thank you for your clarification.
I can update the PG driver to support YugaByte easily if the select version(); return the driver name.
For example:
In PostgreSQL: select version() returns PostgreSQL 11.0;
it would be great if YugaByte returns YugaByte _version_number; So I can change the query based on that information.

That'll be great @huyphams, appreciate it!
Created this issue for us to update select version():https://github.com/YugaByte/yugabyte-db/issues/1841
TablePlus integration will also depend on: https://github.com/YugaByte/yugabyte-db/issues/1284.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lhotari picture lhotari  路  5Comments

rhzs picture rhzs  路  5Comments

joeblew99 picture joeblew99  路  5Comments

bmatican picture bmatican  路  3Comments

robertpang picture robertpang  路  3Comments