Search Postgresql Archives

Re: OID's

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Matt <matt@xxxxxxxx> writes:

> I ask because I'm currently using them to join a single table to rows in
> arbitrary tables, something like:
> 
> +-------------+
> | JOINME      |
> +-------------+
> | foreign_oid |
> | foreign_id  |
> | ...         |
> +-------------+
> 
> Where foreign_oid is the tableoid of the table and foreign_id is the
> (serial, not oid) id of the row in that table.
> 
> I dunno if it's bad design, but it's darn handy.

How do you make use of this? It seems like you would need your code to know
which foreign_oid referred to which table to actually perform the join.


-- 
greg


---------------------------(end of broadcast)---------------------------
TIP 9: the planner will ignore your desire to choose an index scan if your
      joining column's datatypes do not match

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux