这是indexloc提供的服务,不要输入任何密码
Skip to content

pgAdmin 7.5 fails to render table SQL with extension loaded index method #6630

@neilt

Description

@neilt

Describe the bug
When using the extension pgvector (https://github.com/pgvector/pgvector) in a table, pgAdmin4 fails to retrieve the SQL for the table with the complete error message of 'ivfflat'.

Screenshot 2023-07-28 at 10 19 27 AM

The bug relates to the following index creation:

CREATE INDEX ON bot_training_data USING ivfflat (input_vector vector_cosine_ops) WITH (lists = 100);

The following issues exist.

  1. The error report in the pgAdmin dialog is completely useless. It should say something like "did not recognize index method.....".
  2. Even if pgAdmin does not recognize this index method it should not just refuse to work. Not sure of the correct response, but the rest of the SQL for creating the table should appear.
  3. PgAdmin should recognize index methods that are loaded with extensions.

To Reproduce
Create the following in a Postgres 15.3 database:

CREATE EXTENSION vector; 
CREATE TABLE  bot_training_data (input_vector  vector(512) );
CREATE INDEX ON bot_training_data USING ivfflat (input_vector vector_cosine_ops) WITH (lists = 100);

Steps to reproduce the behavior:

  1. After creating the above table and index, go to pgAdmin and select the bot_training_data table.
  2. Go to the SQL tab
  3. See the error

Expected behavior
I expected to see the table SQL as with any other table.

Error message
See above for screenshot

Desktop (please complete the following information):

  • OS: OSX Ventura 13.5
  • PG: PostgreSQL 15.3 on x86_64-apple-darwin22.5.0, compiled by Apple clang version 14.0.3 (clang-1403.0.22.14.1), 64-bit
  • pgAdmin Version: 7.5
  • Mode: Desktop
  • Package type: pgAdmin website app download for macOS.

Additional context
With all of the current and likely future focus on AI and natural language processing, this is an important bug to fix.

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions