spqr icon indicating copy to clipboard operation
spqr copied to clipboard

DROP TABLE with schema does not work

Open Denchick opened this issue 9 months ago • 0 comments

Describe the bug syntax error on pos 25 when you are trying to drop table in format drop schema_name.table_name

To Reproduce

perforator_db_production=> \dt
                                   List of relations
   Schema   |                           Name                           | Type  |   Owner      
------------+----------------------------------------------------------+-------+------------
 perforator | 8b17b52c-965a-4404-a325-cb8c40af9f12_2025-03-01          | table | perforator
 perforator | 8b17b52c-965a-4404-a325-cb8c40af9f12_2025-03-01_unstable | table | perforator
 perforator | 8b17b52c-965a-4404-a325-cb8c40af9f12_2025-03-11          | table | perforator
 perforator | 8b17b52c-965a-4404-a325-cb8c40af9f12_2025-03-11_unstable | table | perforator
 perforator | 9869494e-aea6-4a56-8d29-7eb4d2d6ce8d_2025-03-01          | table | perforator
 perforator | 9869494e-aea6-4a56-8d29-7eb4d2d6ce8d_2025-03-01_unstable | table | perforator
 perforator | eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01          | table | perforator
 perforator | eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01_unstable | table | perforator
 perforator | eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-03-01          | table | perforator
 perforator | eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-03-01_unstable | table | perforator
(10 rows)

perforator_db_production=> DROP TABLE perforator.eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01_unstable /* __spqr__engine_v2: true */;
ERROR:  client processing error: error processing query 'DROP TABLE perforator.eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01_unstable /* __spqr__engine_v2: true */;': syntax error on pos 25, tx status IDLE
perforator_db_production=> DROP TABLE perforator."eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01_unstable" /* __spqr__engine_v2: true */;
ERROR:  client processing error: error processing query 'DROP TABLE perforator."eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01_unstable" /* __spqr__engine_v2: true */;': syntax error on pos 25, tx status IDLE
perforator_db_production=> DROP TABLE perforator.'eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01_unstable' /* __spqr__engine_v2: true */;
ERROR:  client processing error: error processing query 'DROP TABLE perforator.'eed78c80-dcd0-4556-96fd-0e9cf091c175_2025-02-01_unstable' /* __spqr__engine_v2: true */;': syntax error on pos 25, tx status IDLE

Expected behavior You are able to drop a table, either with a specified schema or not.

Denchick avatar Mar 10 '25 16:03 Denchick