The key, I believe, is to outer join your category table twice:
cfquery datasource=calendar name=findcal
SELECT e.category1, e.category2, c1.category_no as cat_no1, c1.descr as
descr1, c2.category_no as cat_no2, c2.descr as descr2
FROM
category c2 RIGHT OUTER JOIN
Al... thanks for the response... I need to show my ignorance what is
a mapping table?
-Original Message-
From: Everett, Al [mailto:AEverett;askallied.com]
Sent: Friday, November 08, 2002 8:27 AM
To: CF-Talk
Subject: RE: help with output from 2 tables
The key, I believe, is to outer
, all
categories for an event, or whatever I need.
-Original Message-
From: Tim Laureska [mailto:hometeam;goeaston.net]
Sent: Friday, November 08, 2002 8:48 AM
To: CF-Talk
Subject: RE: help with output from 2 tables
Al... thanks for the response... I need to show my
ignorance
, Al [mailto:AEverett;askallied.com]
Sent: Friday, November 08, 2002 10:06 AM
To: CF-Talk
Subject: RE: help with output from 2 tables
It's a way to manage many-to-many relationships. One-to-many
relationships
are easy to manage with a foreign key in one table. Once you have to
have
more
Weeg
Senior Web Developer
Information System Design
Navtrak, Inc.
Fleet Management Solutions
www.navtrak.net
410.548.2337
-Original Message-
From: Tim Laureska [mailto:hometeam;goeaston.net]
Sent: Friday, November 08, 2002 3:15 PM
To: CF-Talk
Subject: RE: help with output from 2 tables
tables, but have never dealt with mapping
-Original Message-
From: Tony Weeg [mailto:tony;navtrak.net]
Sent: Friday, November 08, 2002 3:19 PM
To: CF-Talk
Subject: RE: help with output from 2 tables
tim,
hi there. well, first of all, Many-To-Many and Many-To-One
relationships
Is there any recommended reference material on this?
-Original Message-
From: Tony Weeg [mailto:tony;navtrak.net]
Sent: Friday, November 08, 2002 3:19 PM
To: CF-Talk
Subject: RE: help with output from 2 tables
tim,
hi there. well, first of all, Many-To-Many and Many-To-One
with output from 2 tables
Is there any recommended reference material on this?
-Original Message-
From: Tony Weeg [mailto:tony;navtrak.net]
Sent: Friday, November 08, 2002 3:19 PM
To: CF-Talk
Subject: RE: help with output from 2 tables
tim,
hi there. well, first of all, Many-To-Many and Many
-Original Message-
From: Tim Laureska [mailto:hometeam;goeaston.net]
Sent: Friday, November 08, 2002 3:39 PM
To: CF-Talk
Subject: RE: help with output from 2 tables
Tony... I saw the one with the CFloop example (and thank you)... I want
to play with that example, but was curious about/intrigued
Message-
From: Tim Laureska [mailto:hometeam;goeaston.net]
Sent: Friday, November 08, 2002 3:15 PM
To: CF-Talk
Subject: RE: help with output from 2 tables
This sounds very useful but where do you do this relationship
managing/table mapping... is this done as part of a query?
I have
, November 08, 2002 12:40 PM
Subject: RE: help with output from 2 tables
Is there any recommended reference material on this?
-Original Message-
From: Tony Weeg [mailto:tony;navtrak.net]
Sent: Friday, November 08, 2002 3:19 PM
To: CF-Talk
Subject: RE: help with output from 2 tables
tim
tim i think i would do it like this...
cfquery name=getCats datasource=yourDSN
select * from categories
/cfquery
cfloop query=getCats
cfquery name=getEvents datasource=yourDSN
select * from events
where categoryID = #getCats.id#
12 matches
Mail list logo