From: cfaussie@googlegroups.com [mailto:cfaussie@googlegroups.com] On Behalf Of Seona Bellamy
Sent: Tuesday, March 28, 2006 8:10
AM
To: cfaussie@googlegroups.com
Subject: [cfaussie] Re: Dealing
with a random number of images
On 27/03/06, Steve Onnis
[EMAIL PROTECTED]
wrote:
this might
: cfaussie@googlegroups.com [mailto:[EMAIL PROTECTED] Behalf
Of Seona Bellamy
Sent: Tuesday, March 28, 2006 9:53 AM
To: cfaussie@googlegroups.com
Subject: [cfaussie] Re: Dealing with a random number of images
On 28/03/06, Steve Onnis [EMAIL PROTECTED] wrote:
Sorry
Should be just
cfset queryAddColumn
I hadn't thought of doing it that way, but it makes a whole lot of
sense. Thanks for that, I'll have a fiddle with it and see if I can get
it going this way. :)
Cheers,
Seona.On 28/03/06, Steve Onnis [EMAIL PROTECTED] wrote:
the thing is your doing queries where they are not neededall you needed
This is a situation where the group property of cfoutput comes in very handy:cfoutput query=qImages group=prop
!--- Do stuff with a property ---cfoutput!--- Do stuff with each instance of the property, eg process an image field ---
/cfoutput/cfoutputCheersBlair
On 3/22/06, Brett Payne-Rhodes
On 23/03/06, Shib71 [EMAIL PROTECTED] wrote:
This is a situation where the group property of cfoutput comes in very handy:cfoutput query=qImages group=prop
!--- Do stuff with a property ---cfoutput!--- Do stuff with each instance of the property, eg process an image field ---
Would it be practical to store the image ids as a list and use that?BlairOn 3/23/06, Seona Bellamy [EMAIL PROTECTED]
wrote:On 23/03/06,
Shib71 [EMAIL PROTECTED] wrote:
This is a situation where the group property of cfoutput comes in very handy:cfoutput query=qImages group=prop
!--- Do stuff
---
From: cfaussie@googlegroups.com
[mailto:[EMAIL PROTECTED] On Behalf Of Seona
BellamySent: Thursday, 23 March 2006 8:46 AMTo:
cfaussie@googlegroups.comSubject: [cfaussie] Re: Dealing with a
random number of images
...
So can anyone else
.
From: cfaussie@googlegroups.com
[mailto:cfaussie@googlegroups.com] On Behalf Of Seona
BellamySent: Thursday, 23 March 2006 8:46 AMTo:
cfaussie@googlegroups.comSubject: [cfaussie] Re: Dealing with a
random number of images
...
So can anyone else come up with a way
I can write this query so
Hi Seona,Scott's idea to have the property'simage
number (1-5) stored with image would reduce complexity of ensuring each joined
record is for a different image.Did some testing it looks like the
check to get unique images needs to go with the LEFT JOIN constraints as I
thinkScott was
If I'm reading you right, all your concerns are serverside..
Problem 1
Seems simple enough...
cfquery name=images
SELECT *
FROM re_Image
WHERE propID = #whatever# --Use cfqueryparam... too lazy to type
/cfquery
Once you have that,
if images.recordcount gt 0{
//you have images,
On 22/03/06, Haikal Saadh [EMAIL PROTECTED] wrote:
If I'm reading you right, all your concerns are serverside..Problem 1Seems simple enough...cfquery name=images SELECT * FROM re_Image WHERE propID = #whatever#--Use cfqueryparam... too lazy to type
/cfqueryOnce you have that,if images.recordcount
On 22/03/06, Scott Thornton [EMAIL PROTECTED] wrote:
Hello,If you wish to use one query only, and have to deal with 0-n images, then you will have to left outer join your Image table.egselect*fromre_property prop left outer joinre_image image on
prop.propid = image.propid
Ah! I've never understood
Hi Seona,
Almost right...
If you are sure there will always be an agent for a property then use:
select *
from re_property prop, re_agent agent
left outer join re_image image
on image.propid = prop.propid
where agent.propID = prop.propID
Use 'left outer join' when you're not sure
Just jumping in from left field here and may not be of help, but have
you ever used MS Access? I find it quite handy as a drag and drop SQL
generator. I tend to recreate all my databases in Access so I can
hack and play and have it create the SQL for me. I know Enterprise
does the same, but I
On 22/03/06, Chad Renando [EMAIL PROTECTED] wrote:
Just jumping in from left field here and may not be of help, but haveyou ever used MS Access?I find it quite handy as a drag and drop SQLgenerator.I tend to recreate all my databases in Access so I canhack and play and have it create the SQL for
15 matches
Mail list logo