Hi Denis,
Its a bug. The problem is the JDBC driver (and its not just PostgreSQL)
can return more than just tables for DataBaseMetaData.getTables. Oracle
for instance will return synonyms as well as views.
What I could do is use the table type in the drop command. E.G.
DROP TABLE
DROP VIEW
DROP SYNONYM
This wouldn't be 100% correct (e.g. SYSTEM TABLE is a common table type)
but would be better than the current situation.
--
Colin Bell
http://squirrel-sql.sf.net
----- Original Message -----
From: "Denis Grannell" <dgr...@we...>
Date: Sunday, May 4, 2003 4:26 am
Subject: [Squirrel-sql-users] Possible bug in 'drop' function
> Hi,
>
> I think I've stumbled on a bug in squirrel 1.1-Final
> when accessing a Postgres 7.3.2 database.
> To reproduce:
>
> 1. Create a view in a database
>
> 2. Refresh the Objects tree.
> (The new view appears under 'View')
>
> 3. Right click on the view name and select 'Drop'
>
> 4. A confirmation popup opens with "Are you sure?"
>
> 5. Execute the drop
>
> 6. The following error message appears:
> java.sql.SQLException: ERROR: "<Your-View-Name>" is not a
> table.
> Use DROP VIEW to remove a view
>
> 7. The view is not removed.
>
> cheers,
> Denis
>
>
> Denis Grannell, Kapuzinerstr. 45, D-80469 Muenchen
> Tel: +49 89 201 3672 Fax: +49 89 202 2875
> _/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
>
>
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Squirrel-sql-users mailing list
> Squ...@li...
> https://lists.sourceforge.net/lists/listinfo/squirrel-sql-users
>
|