Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Setting up new "relations" between tables

Quote Reply
Setting up new "relations" between tables
Hi,

I'm trying to setup a "relation" between 2 tables:

Advert_Relations
Adverts

Both tables have a field called "ID", and I need to link these together.

How would I do that? I've had a look in install.cgi/install.dat to see how its done on the Links/CatLinks (and other) tables - but can't for the life of me see it :(

TIA

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] Setting up new "relations" between tables In reply to
Just look at any one of the table relations in Links/SQL.pm. In particular the 'fk' key.

Adrian
Quote Reply
Re: [brewt] Setting up new "relations" between tables In reply to
Hi,

Turned out to be quite complex what I wanted to do - so had to just do it with a SQL query, and then use do_query() Smile

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!