Slony-I 2.2.10 Documentation
Prev | Fast Backward | Chapter 8. Schema schemadoc | Fast Forward | Next

# 8.17. View: `sl_seqlastvalue`

Structure of `sl_seqlastvalue`

`seq_id`

  `integer`

`seq_set`

  `integer`

`seq_reloid`

  `oid`

`seq_origin`

  `integer`

`seq_last_value`

  `bigint`

Figure 8-2. Definition of view sl_seqlastvalue

    SELECT sq.seq_id
    ,
        sq.seq_set
    ,
        sq.seq_reloid
    ,
        s.set_origin AS seq_origin
    ,
        sequencelastvalue
    (
         (
               (quote_ident
                     (
                           (pgn.nspname)::text
                     ) || '.'::text
               ) || quote_ident
               (
                     (pgc.relname)::text
               )
         )
    ) AS seq_last_value

    FROM sl_sequence sq
    ,
        sl_set s
    ,
        pg_class pgc
    ,
        pg_namespace pgn

    WHERE (
         (s.set_id = sq.seq_set)
       AND (pgc.oid = sq.seq_reloid)
       AND (pgn.oid = pgc.relnamespace)
    );

Prev | Home | Next
Table: `sl_registry` | Up | Table: `sl_seqlog`