Hypothetical SQL question:
I have a table called PEOPLE and a table called GRADES. I'd like to return a
list of people and all of their grades and then output the results in a
cfoutput, grouping by peopleID. Ok, that's easy enough, but what if I only
want to return people that have an A as one
#'
/CFQUERY
Steven Lancaster
Barrios Technology
NASA/JSC
281-244-2444 (voice)
[EMAIL PROTECTED]
-Original Message-
From: Cantrell, Adam [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 28, 2002 10:32 AM
To: CF-Talk
Subject: Hypothetical SQL question
Hypothetical SQL question:
I have
= A)
Cantrell, Adam [EMAIL PROTECTED] 03/28/02 11:31AM
Hypothetical SQL question:
I have a table called PEOPLE and a table called GRADES. I'd like to return a
list of people and all of their grades and then output the results in a
cfoutput, grouping by peopleID. Ok, that's easy enough, but what
I'd do it.
Jamie
On Thu, 28 Mar 2002 10:31:30 -0600, in cf-talk you wrote:
Hypothetical SQL question:
I have a table called PEOPLE and a table called GRADES. I'd like to return a
list of people and all of their grades and then output the results in a
cfoutput, grouping by peopleID. Ok, that's easy
:[EMAIL PROTECTED]]
Sent: Thursday, March 28, 2002 11:32 AM
To: CF-Talk
Subject: Hypothetical SQL question
Hypothetical SQL question:
I have a table called PEOPLE and a table called GRADES. I'd like to
return a
list of people and all of their grades and then output the results in a
cfoutput
: LANCASTER, STEVEN M. (JSC-OL) (BAR)
[mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 28, 2002 10:44 AM
To: CF-Talk
Subject: RE: Hypothetical SQL question
Hope this helps :)
cfset goodgrade = A
CFQUERY name=getgradeA datasource=datasource
Select Distinct people.people
-Original Message-
From: Cantrell, Adam [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 28, 2002 8:32 AM
To: CF-Talk
Subject: Hypothetical SQL question
Hypothetical SQL question:
I have a table called PEOPLE and a table called GRADES. I'd like to return a
list of people and all
Jackson [mailto:[EMAIL PROTECTED]]
Sent: 28 March 2002 16:48
To: CF-Talk
Subject: Re: Hypothetical SQL question
select *
from people, grades
where people.id = grades.peopleID
and people.id in (
select people.id
from people, grades
where people.id = grades.peopleID
: Hypothetical SQL question
select *
from people, grades
where people.id = grades.peopleID
and people.id in (
select people.id
from people, grades
where people.id = grades.peopleID
and grades.grade = 'a'
)
Something like that? May have screwed up
9 matches
Mail list logo