How do I Drop Table from slony -


i have database being backed slony. dropped table replicated db , re-created same table using sql scripts , nothing through slony scripts.

i found on post , tried it:

  1. recreate table
  2. get oid recreated table: select oid pg_class relname = <your_table>' , relkind = 'r';
  3. update tab_reloid in sl_table problem table.
  4. execute set drop table ( origin = n, id = zzz); n node # master, , zzz id # in sl_table.

but doesn't seem work.

how drop table replicated db? or there way use newly created table in place of old one?

the authoritative documentation on dropping things slony here.

it's not clear state things in before ran commands above, , haven't clarified "doesn't seem work".

there 1 significant "gotcha" know off dropping tables replication slony. after remove table replication, can have trouble physically dropping table on slaves (but not on master) slony 1.2, getting cryptic error this:

error:  "table_pkey" index 

this may fixed in slony 2.0, problem here there referential integrity relationship between unreplicated table on slave , replicated table, , slony 1.2 has intentionally corrupted system table part of it's design, causing issue.

a solution run "drop table" command through slonik_execute_script. if have physically dropped table on master, can use option "execute on" run command on specific slave. see docs execute script details.


Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

c# - How to add a new treeview at the selected node? -

java - netbeans "Please wait - classpath scanning in progress..." -