Merge pull request #1862 from gilmoskowitz/i24559_xtlocks
authorSteve Hackbarth <stephenhackbarth@gmail.com>
Fri, 19 Sep 2014 16:29:27 +0000 (12:29 -0400)
committerSteve Hackbarth <stephenhackbarth@gmail.com>
Fri, 19 Sep 2014 16:29:27 +0000 (12:29 -0400)
issue #24559 - add cascade

enyo-client/database/source/wipe_views.sql

index b921575..2116aec 100644 (file)
@@ -4,7 +4,7 @@ do $$
 declare
   sqlstring text;
 begin
-  select string_agg('drop view ' || t.oid::regclass || ';', ' ') into sqlstring
+  select string_agg('drop view if exists ' || t.oid::regclass || ' cascade;', ' ') into sqlstring
     from pg_class t
     join pg_namespace n on n.oid = relnamespace
    where relkind = 'v'