[GENERAL] Re: Re: Test for existence of Table

2001-01-05 Thread Gregory Wood
DROP TABLE employees Error: ERROR: Relation 'employees' does not exist And execution halts which is I believe why he wanted to check for the existence before trying to DROP. I'd love to know if this exists as well... would come in very handy during development time. Execution does

Re: [GENERAL] Re: Re: Test for existence of Table

2001-01-05 Thread Ed Loehr
Gregory Wood wrote: What would be nice is if there were a way to only DROP a table if it exists. But I would consider this to be rather low priority. This might help... CREATE FUNCTION table_exists(TEXT) RETURNS BOOLEAN AS 'DECLARE tablename ALIAS FOR $1; temp RECORD; BEGIN