Tue Jul 27 15:42:06 PDT 2004
- Previous message: [Slony1-general] Parser Stack Overflow
- Next message: [Slony1-general] Parser Stack Overflow
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Jul 27, 2004, at 9:24 AM, Christopher Browne wrote: > [Aside: I suspect you meant "to configure slonik to avoid the stack > overflow"...] Yes, I did. > One way would be to not use slonik, but rather to directly use the > plpgsql function that is used to add tables to the set: > > -- > ---------------------------------------------------------------------- > -- FUNCTION setAddTable (set_id, tab_id, tab_fqname, tab_idxname, > -- tab_comment) > -- > ---------------------------------------------------------------------- > > If you threw in a custom sequence to generate tab_id values, this > could be used alongside a query against pg_class (joined against > itself in order to locate suitable indices) to generate the table set > all in one query. Hmm. Interesting. So are the plpgsql functions themselves documented somewhere? Well, in the meantime, I'll post my first attempt at automating this process. See http://www.sitening.com/meta-slonik for a slonik script builder. It basically builds the three main sections of the slonik script: sequences, tables with primary keys, and tables without primary keys. It should work fine for reasonably sized databases. It just turns out that I'm at the limits of what slonik seems to have been built for. I'd appreciate developer and user comments to see whether this idea could be improved. It's basically what I've been describing that I'd like: a simple way to replicate an entire database. -tfo
- Previous message: [Slony1-general] Parser Stack Overflow
- Next message: [Slony1-general] Parser Stack Overflow
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-general mailing list