I have two separate queries, basically a table of NEW stuff, and then a
table of OLD stuff that's not been converted to new yet. Not all fields
in the two tables match.
So, first query finds all the matching NEW things
Second query finds all the OLD things that aren't present in the NEW
You need to alias the columns in the original queries to they both match,
and you must have same number of colums, so exclude the ones that don't
exist in both tables.
Regards
Russ Michaels
www.michaels.me.uk
www.cfmldeveloper.com - Free CFML hosting for developers
www.cfsearch.com - CF search
Is there a way around this?
Just create empty columns when they are missing, ie:
*SELECT*
first_name,
last_name,
off1_name,
off2_name,
off3_name,
atty_id,
email
FROM newstuff
UNION
SELECT
first_name,
last_name,
On 1/29/2013 4:16 PM, =?ISO-8859-1?Q?Claude_Schn=E9egans wrote:
Just create empty columns when they are missing, ie:
'' AS off1_name,
Ahhh - that works! Didn't know you could do that!
Thanks
~|
Order the Adobe
Two tables each containing a shared primary key ID.
I am trying to create a query that lists records from table B that are not
in table A.
Many thanks,
Jenny
~|
Order the Adobe Coldfusion Anthology now!
select * from b where id not in (select id from a)
On Tue, Jun 21, 2011 at 12:37 PM, Jenny Gavin-Wear
jenn...@fasttrackonline.co.uk wrote:
Two tables each containing a shared primary key ID.
I am trying to create a query that lists records from table B that are not
in table A.
Many
if your tables are large, you'll probably see a better performance from
select id from TableA a
where not exists
(select 1 from TableB b
where a.id = b.id)
On Tue, Jun 21, 2011 at 12:41 PM, John M Bliss bliss.j...@gmail.com wrote:
select * from b where id not in (select id from a)
On Tue,
Thanks John and Greg :)
-Original Message-
From: Greg Morphis [mailto:gmorp...@gmail.com]
Sent: 21 June 2011 18:45
To: cf-talk
Subject: Re: SQL Query Problem
if your tables are large, you'll probably see a better performance from
select id from TableA a
where not exists
(select 1
How about:
select b.*
from b
left outer join a on b.id = a.id
where a.id is null
Carl
On 6/21/2011 10:37 AM, Jenny Gavin-Wear wrote:
Two tables each containing a shared primary key ID.
I am trying to create a query that lists records from table B that are not
in table A.
Many thanks,
I would do it this way :
select b.*
from b
where b.id not in (select a.id from a)
How about:
select b.*
from b
left outer join a on b.id = a.id
where a.id is null
Carl
On 6/21/2011 10:37 AM, Jenny Gavin-Wear wrote:
~|
That looks familiar! :-)
On Tue, Jun 21, 2011 at 1:09 PM, Stephane Vantroyen s...@emakina.com wrote:
I would do it this way :
select b.*
from b
where b.id not in (select a.id from a)
How about:
select b.*
from b
left outer join a on b.id = a.id
where a.id is null
Carl
On
Looks like I went with the vote, lol
Many thanks for all replies, and fast too :)
Some payments from Paypal transactions, some manually entered on profiles.
Legacy code :/
Jenny
select * from tbl_members
where
(datepart(m,paid) = #session.month# and datepart(,paid) = #session.year#
AND
Off topic, but the Select * made me shudder.
On Tue, Jun 21, 2011 at 2:25 PM, Jenny Gavin-Wear
jenn...@fasttrackonline.co.uk wrote:
Looks like I went with the vote, lol
Many thanks for all replies, and fast too :)
Some payments from Paypal transactions, some manually entered on
+420
On Tue, Jun 21, 2011 at 2:45 PM, Michael Grant mgr...@modus.bz wrote:
Off topic, but the Select * made me shudder.
On Tue, Jun 21, 2011 at 2:25 PM, Jenny Gavin-Wear
jenn...@fasttrackonline.co.uk wrote:
Looks like I went with the vote, lol
Many thanks for all replies, and fast
She didn't provide column names...
On Tue, Jun 21, 2011 at 1:45 PM, Michael Grant mgr...@modus.bz wrote:
Off topic, but the Select * made me shudder.
On Tue, Jun 21, 2011 at 2:25 PM, Jenny Gavin-Wear
jenn...@fasttrackonline.co.uk wrote:
Looks like I went with the vote, lol
Many
I was waiting for a comment on that.
It's a very small table :)
-Original Message-
From: Michael Grant [mailto:mgr...@modus.bz]
Sent: 21 June 2011 19:46
To: cf-talk
Subject: Re: SQL Query Problem
Off topic, but the Select * made me shudder
, Jenny Gavin-Wear
jenn...@fasttrackonline.co.uk wrote:
I was waiting for a comment on that.
It's a very small table :)
-Original Message-
From: Michael Grant [mailto:mgr...@modus.bz]
Sent: 21 June 2011 19:46
To: cf-talk
Subject: Re: SQL Query Problem
Off topic, but the Select
Hi Michael,
The (very old) web site is about to be completely redeveloped, so I'm really
not too worried.
Appreciate your concern though :)
Jenny
-Original Message-
From: Michael Grant [mailto:mgr...@modus.bz]
Sent: 21 June 2011 23:27
To: cf-talk
Subject: Re: SQL Query Problem
: Michael Grant [mailto:mgr...@modus.bz]
Sent: 21 June 2011 23:27
To: cf-talk
Subject: Re: SQL Query Problem
Right, but if that table grows and columns are added, the overhead on
your
query will grow. Having a small table makes it even easier to define the
columns in your select list
HI everybody,,
Am stucked... I have a query with 9 rows. I need to store every row into a
different distinct variable. my query is listed below
cfquery name=getcs datasource=#datasource#
SELECT COUNT(s.id) AS cscount
FROMSociety s
WHERE s.gr='cs'
group by s.asst
/cfquery
cfoutput
I need to store every row
into a different distinct variable.
You probably don't, and should instead be using an array.
MyValues = ListToArray( ValueList( MyQuery.ColumnName ) )
Then you can do MyValues[1] to MyValues[9] to get at the variables.
If you *really* need to create individual
Thanks will do that then
I need to store every row
into a different distinct variable.
You probably don't, and should instead be using an array.
MyValues = ListToArray( ValueList( MyQuery.ColumnName ) )
Then you can do MyValues[1] to MyValues[9] to get at the variables.
If you
Just to throw out another solution, you can get the same result you
initailly tried by doing the following:
cfloop query=getcs
cfset variables[rowgetcs.currentRow] = getcs.cscount /
/cfloop
On Thu, May 28, 2009 at 7:58 AM, Peter Boughton bought...@gmail.com wrote:
I need to store every
And finally, you could simpy reference the original query using array
notation (e.g. getcs[cscount][1], getcs[cscount][2] etc) and avoid
the extra work.
mxAjax / CFAjax docs and other useful articles:
http://www.bifrost.com.au/blog/
2009/5/28 Scott Stroz boyz...@gmail.com:
Just to throw out
Instead of cast('#form.test#' as int(4)) I'd try #val(form.test)# and
a cfqueryparam would probably help the situation as well
Original Message ---
I have a input box wher I am getting the value for my where clause.
INstead I am getting the error Error
I have a input box wher I am getting the value for my where clause. INstead I
am getting the error Error converting the varchar value to a column of data
type int
cfquery name=infoNote datasource=X
SELECT apr.reqid, apr.requirement,
why do you need to use cast?
can't you just use cfqueryparam cfsqltype=cf_sql_integer
value=#form.test#?
--
Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com
~|
Check out the new features and enhancements in the
latest
Instead of cast('#form.test#' as int(4)) I'd try #val(form.test)# and a
cfqueryparam would probably help the situation as well
Original Message ---
I have a input box wher I am getting the value for my where clause. INstead I
am getting the error Error converting the
Message-
From: James Holmes [mailto:[EMAIL PROTECTED]
Sent: Thursday, December 28, 2006 9:51 PM
To: CF-Talk
Subject: Re: Query Problem
You have a query with 100 rows and you are trying to set a cell in row
1920. 1920 is greater than 100.
On 12/29/06, Bruce Sorge [EMAIL PROTECTED] wrote:
Hello.
I
it crated
2020 rows which sucked.
Thanks
-Original Message-
From: James Holmes [mailto:[EMAIL PROTECTED]
Sent: Thursday, December 28, 2006 9:51 PM
To: CF-Talk
Subject: Re: Query Problem
You have a query with 100 rows and you are trying to set a cell in row
1920. 1920 is greater
: Query Problem
You have a query with 100 rows and you are trying to set a cell in row
1920. 1920 is greater than 100.
On 12/29/06, Bruce Sorge [EMAIL PROTECTED] wrote:
Hello.
I have these three queries that I am creating below. The first two
work
great, but the third one gives me
Hello.
I have these three queries that I am creating below. The first two work
great, but the third one gives me the following error:
The row number, (1920) is out of bound. This is happening on line 48 which
is this one:
cfset temp = QuerySetCell(yearQuery, year_num, #yearnumber[year_number]#,
You have a query with 100 rows and you are trying to set a cell in row
1920. 1920 is greater than 100.
On 12/29/06, Bruce Sorge [EMAIL PROTECTED] wrote:
Hello.
I have these three queries that I am creating below. The first two work
great, but the third one gives me the following error:
The
varchar(255),
year smallint(5) unsigned
- Original Message -
From: Jim McAtee [EMAIL PROTECTED]
To: CF-Talk cf-talk@houseoffusion.com
Sent: Sunday, November 05, 2006 11:22 PM
Subject: Query Problem
I have a database of music CDs, something like:
album
-
albumid int(10
06, 2006 7:37 AM
To: CF-Talk
Subject: Re: Query Problem
Looks like you might need to add an additional field to your albums table.
Then populate it with the artists id's that are associated with speccific
albums. Also might want to add the same to your track table.
albumid int(10) unsigned
Actually I think that would be a grouping issue (once you fixed the 'seletc'
type)... and I hate 'GROUP BY' clauses... they get me every time!
At the risk of being bashed for using 'IN'... try this
select albumtitle, name, year
from album, artist
where albumid =
Actually, you should use a inner join on that, so not to return records you
do not need.
~|
Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting,
up-to-date ColdFusion information by your peers, delivered
I tend to find that exists is very helpful for these situation (and reads
like the english version of what I want).
SELECT artistid,name
FROMartist
WHERE EXISTS (
SELECT artistid
FROMtrack
INNER JOIN artisttrack
-
From: Doug Brown [mailto:[EMAIL PROTECTED]
Sent: Monday, November 06, 2006 9:10 AM
To: CF-Talk
Subject: Re: Query Problem
Actually, you should use a inner join on that, so not to return records you
do not need.
~|
Introducing
- Original Message -
From: Bobby Hartsfield [EMAIL PROTECTED]
To: CF-Talk cf-talk@houseoffusion.com
Sent: Monday, November 06, 2006 7:14 AM
Subject: RE: Query Problem
Im not sure which one you mean. The first one I posted DID use inner joins
and the problem was of course returning the same
.
Joshua
-Original Message-
From: Steve Bryant [mailto:[EMAIL PROTECTED]
Sent: Monday, November 06, 2006 8:03 AM
To: CF-Talk
Subject: Re: Query Problem
I tend to find that exists is very helpful for these situation (and reads
like the english version of what I want).
SELECT artistid,name
Ahh gotcha. Still hasnt come through. Im sure you can see why I thought you
meant mine thoguh ;-)
cheers
-Original Message-
From: Doug Brown [mailto:[EMAIL PROTECTED]
Sent: Monday, November 06, 2006 9:20 AM
To: CF-Talk
Subject: Re: Query Problem
Weird. I had sent a query and it posted
Use select distinct on the original query to eliminate duplicate records.
I have a database of music CDs, something like:
album
-
albumid int(10) unsigned NOT NULL auto_increment,
albumtitle varchar(255),
year smallint(5) unsigned
track
-
trackid int(10) unsigned NOT
: Query Problem
Adding the artistid to the album table would cause some SERIOUS redundant
data... take Peeping Tom... there are at least 20 different artists on
that
album. Adding artistid to the album table would mean you needed to add the
same album 20 times with a different artistid each
: Query Problem
Adding the artistid to the album table would cause some SERIOUS redundant
data... take Peeping Tom... there are at least 20 different artists on
that
album. Adding artistid to the album table would mean you needed to add the
same album 20 times with a different artistid each time
I have a database of music CDs, something like:
album
-
albumid int(10) unsigned NOT NULL auto_increment,
albumtitle varchar(255),
year smallint(5) unsigned
track
-
trackid int(10) unsigned NOT NULL auto_increment,
tracktitle varchar(255),
tracknumber smallint(5)
I have a table that has repair ticket information and another one
that has information about technicians. The repair ticket column
technician contains a number that references the ID in the
technician database: tecnicians REFERENCES people_alt(people_alt_id)
I query like this (see below)
Daniel Kessler wrote ..
Any advice on how to approach this is appreciated.
Change it to a LEFT JOIN, which will always pull in the data from the
repair_ticket table, and return NULL in the columns from people_alt if there is
no match...
CFQUERY NAME=getSelect DATASOURCE=dpch
SELECT
oh man that worked GREAT!
I suppose the issue is that with the left join, there is no dependency on the
other database. It just joins the fields. I hope this is a lesson learned.
thank a bunch - very hearty smile here...
daniel
Change it to a LEFT JOIN, which will always pull in the data
On Friday 04 August 2006 17:19, Kris Jones wrote:
(which just doesn't work at all)
It was meant to be in a loop.
O(N), of course, but that's not so bad with only a few cats.
Going with a linking table is probably the right way to go. Better
performance too.
Very, very, much the +1'ness :-)
You can turn this
SELECT catid FROM deep_images
WHERE catid LIKE '#uid#'
OR catid LIKE '#UID#,%'
OR catid LIKE '%,#UID#'
OR catid LIKE '%,#UID#,%'
INTO this and it should do what your looking to do.
SELECT catid FROM deep_images
WHERE 0=0
AND (catid = '#uid#'
OR
On Thursday 03 August 2006 18:43, Kris Jones wrote:
SELECT catid FROM deep_images WHERE #uid# IN (catid)
IN is evil.
It will randomly stop working when you hit the db's limit for items in a
string list.
Which is not fun :-)
If you must have comma lists rather than a more sensible layout, why
-
From: Tom Chiverton [mailto:[EMAIL PROTECTED]
Sent: Friday, August 04, 2006 9:30 AM
To: CF-Talk
Subject: Re: Query problem with lists of values
On Thursday 03 August 2006 18:43, Kris Jones wrote:
SELECT catid FROM deep_images WHERE #uid# IN (catid)
IN is evil.
It will randomly stop
but one item has entries of 15,16,30,49,50,52,75 and it is being put in
a catecory that has the id of 2 there are lots of these that are
behaving this way. any one think of a way to help with this?
SELECT catid FROM deep_images WHERE #uid# IN (catid)
IN is evil.
It will randomly stop
here is the problem again I have a sql server with cold fusion mx my
database has a field for categories it contains a comma delim list of
categories to which each product belongs the prob is when I try to
create a drop down list for them it is giving me all kinds of weird results.
cfquery
but one item has entries of 15,16,30,49,50,52,75 and it is being put in
a category that has the id of 2 there are lots of these that are
behaving this way. any one think of a way to help with this?
This is happening of course because two of your like clauses catid LIKE
'#uid#' AND catid LIKE
How about:
SELECT catid FROM deep_images WHERE #uid# IN (catid)
Cheers,
Kris
but one item has entries of 15,16,30,49,50,52,75 and it is being put in
a category that has the id of 2 there are lots of these that are
behaving this way. any one think of a way to help with this?
that is kind of what I thought, but is there any way around this?
This is happening of course because two of your like clauses catid LIKE
'#uid#' AND catid LIKE '#uid#,' means that the 2 will match the 2 in '52,'.
This is the difficulty with this kind of set up.
--
Patrick Forsythe
Tech
Kris Jones wrote:
How about:
SELECT catid FROM deep_images WHERE #uid# IN (catid)
Cheers,
Kris
I had tried that originally and sql server didn't like that much at all
--
Patrick Forsythe
Tech Support
Smallville Communications
http://www.toto.net
Guter Rat ist teuer. --Unbekannt
Why don't you use a join table via which to associate your items and
categories?
Josh
-Original Message-
From: Patrick Forsythe [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 03, 2006 1:47 PM
To: CF-Talk
Subject: Re: Query problem with lists of values
that is kind of what I thought
03, 2006 12:49 PM
To: CF-Talk
Subject: Re: Query problem with lists of values
Kris Jones wrote:
How about:
SELECT catid FROM deep_images WHERE #uid# IN (catid)
Cheers,
Kris
I had tried that originally and sql server didn't like that much at all
--
Patrick Forsythe
Tech Support
Smallville
On 8/3/06, Mark A Kruger [EMAIL PROTECTED] wrote:
Patrick,
You can create a UDF that allows for list functions. Here's blog post on the
topic.
http://mkruger.cfwebtools.com/index.cfm?mode=entryentry=87616A7F-D611-F201-
A72DB4B567CFA1F7
The UDF that Mark is blogging about looks like it
the category information is in a seperate row these are only the uid s
that are stored with the product.
Jim Wright wrote:
The UDF that Mark is blogging about looks like it will get you what
you want, but do keep in mind that if you use a UDF like this in the
WHERE clause, it will be executed
On 8/3/06, Patrick Forsythe [EMAIL PROTECTED] wrote:
the category information is in a seperate row these are only the uid s
that are stored with the product.
Understood...but what you need is an intermediate table which links
the two...something like...
category table:
uid
description
You might want to test the boundary cases because the time portion of
datetimes can cause trouble for you.
Adrian
-Original Message-
From: Les Mizzell [mailto:[EMAIL PROTECTED]
Sent: 18 May 2006 05:28
To: CF-Talk
Subject: Re: ARGH! - Three Months in the future query problem
Duh
PROTECTED]
To: CF-Talk cf-talk@houseoffusion.com
Sent: Wednesday, May 17, 2006 10:28 PM
Subject: Re: ARGH! - Three Months in the future query problem
Duh!
This does it:
WHERE event_date #threemonths# and
event_date = #startDATE#
See! Getting away from the computer and thinking about
Mizzell [EMAIL PROTECTED]
To: CF-Talk cf-talk@houseoffusion.com
Sent: Wednesday, May 17, 2006 10:28 PM
Subject: Re: ARGH! - Three Months in the future query problem
Duh!
This does it:
WHERE event_date #threemonths# and
event_date = #startDATE#
See! Getting away from the computer
OK, starting with January through September - this works great. It pulls
up the current month and the next three months worth of events.
cfset startDATE = #now()#
cfset threemonths = DateAdd(m,3,startDATE)
cfquery name=calendar
SELECT
id, event_date, event_name FROM events
WHERE
why not try a BETWEEN '' and ''
where you fill the '' and '' with the REAL dates...
that will get everything in between, and the ones
that are directly on the date.
rather than just looking at the month, since 1 is less than 12
you can do the between, which follows date rules.
tw
On 5/17/06,
Duh!
This does it:
WHERE event_date #threemonths# and
event_date = #startDATE#
See! Getting away from the computer and thinking about things while
walking your dogs really helps!!
cfset startDATE = #now()#
cfset threemonths = DateAdd(m,3,startDATE)
cfquery name=calendar
SELECT
: Michael T. Tangorre [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 08, 2006 10:40 PM
To: CF-Talk
Subject: RE: Query Problem - sorting
From: Dennis Powers [mailto:[EMAIL PROTECTED]
SELECT FilesCategory.Cat_Name,
Avg(Comments.Numeric1) AS Userrating,
Count(Comments.Numeric1
I am hoping some one can asset me with obtaining the proper sorting for this
aggregate query. I just can't see it.
Basically I wish to sort by Userrating, but only on records that have a
Responses count greater that 8.
SELECT FilesCategory.Cat_Name,
Avg(Comments.Numeric1) AS
From: Dennis Powers [mailto:[EMAIL PROTECTED]
SELECT FilesCategory.Cat_Name,
Avg(Comments.Numeric1) AS Userrating,
Count(Comments.Numeric1) AS Responses
FROM (FilesData LEFT JOIN Comments ON FilesData.ID =
Comments.LinkID) LEFT JOIN FilesCategory ON
[empty string] is CF's way of saying NULL, since ColdFusion has not native
NULL value.
Thus your where clause should be WHERE Publication_Type IS NOT NULL
didn't work, but this did. Interestingly, != NULL didn't work. It had to
be IS NOT NULL
I never would have gotten this. I was thinking
I can't seem to see what is wrong with this query. I added the WHERE
line and it comes up with no records returned. Without the WHERE, it
comes up with two records, but one of them has publication_type as an
empty field. I know there are records that aren't empty. Here's the
query:
[empty string] is CF's way of saying NULL, since ColdFusion has not native NULL
value.
Thus your where clause should be WHERE Publication_Type IS NOT NULL
--
Ian Skinner
Web Programmer
BloodSource
www.BloodSource.org
Sacramento, CA
C code. C code run. Run code run. Please!
-
not equals in sql is , that may help
On 9/28/05, Daniel Kessler [EMAIL PROTECTED] wrote:
I can't seem to see what is wrong with this query. I added the WHERE
line and it comes up with no records returned. Without the WHERE, it
comes up with two records, but one of them has publication_type
From: Daniel Kessler [mailto:[EMAIL PROTECTED]
CFQUERY NAME=the_type DATASOURCE=dpch
select publication_type
from publications
where publication_type !=''
group by publication_type
/CFQuery
If the field is NOT NULL try,
where LEN(TRIM(publication_type)) == 0
*note...
In case the default value returned by the db is an empty string, you may
need the belt and the suspenders:
where NOT (publication_type IS NULL OR publication_type = '')
--
___
REUSE CODE! Use custom tags;
See
CAN YOU FIIP/FLOP VARIABLES AND DATA IN CF?
This works in the SQL Query Analyzer. Is there a way to switch it to CF? When I
run it I get the following error.
[SQLServer JDBC Driver][SQLServer]Invalid column name 'DateFrom'.
Because DateFrom is a passed variable.
Select * RENTALS r
Where NOT
Impressive use of your noggin. Hopefully I can explain my problem a little
better. I have changed my data import to create a date record for every night.
Instead of the arrival date and number of nights. I can easily change back it
this doesn't provide the results the best way. Below is some
This looks like a good use of a Tally table. A Tally table is a table that
contains just an ID field with records from 1 to 10,000 (you can use any upper
bound you need). You can then join this table to generate queries based on
ranges.
To test, I created the following table:
ID int
I have 2 tables, one lists properties and the other contains arrival dates and
number of nights for those properties. The common variable is 'unitCode'. The
search parameters provide an arrival date and departure date.
My question. How would you use the arrival date/number of nights to locate
Change it so it has an arrival date and a departure date? :D
On 7/28/05, Doug Bedient [EMAIL PROTECTED] wrote:
I have 2 tables, one lists properties and the other contains arrival dates
and number of nights for those properties. The common variable is 'unitCode'.
The search parameters
I would still have dates between the arrival date and newly created departure
date that would need to be handled somehow. Originally, I had looping set up to
create a record for every date but it seemed like a lot of extra processing
that shouldn't be required.
I don't think you can do it in a single SQL statement. At least not
an efficient one.
How about pull the list of reservations that overlap the desired
dates, and then creating an array of dates (from arrival to
departure), and then loop over the recordset and remove dates from
the array that are
Can you not use the SQL operator BETWEEN?
where thedate BETWEEN arrivaldate AND departuredate
?
-Original Message-
From: Doug Bedient [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 28, 2005 2:47 PM
To: CF-Talk
Subject: Re: Query Problem - Brain Cloud
I would still have dates between
Add a vacant field and check to see if vacant is 0 or 1 0 being not
vacant and 1 being vacant?
But the where clause would look something like
Select * from task t
WHERE TO_DATE('#arguments.new_to#','mm/dd/') = t.startDate
AND TO_DATE('#arguments.new_from#','mm/dd/') = t.finishDate
, July 28, 2005 11:47 AM
To: CF-Talk
Subject: Re: Query Problem - Brain Cloud
I would still have dates between the arrival date and newly created
departure date that would need to be handled somehow. Originally, I had
looping set up to create a record for every date
Something like this wouldn't handle them
where arrivaldate = #arrivaldate# and departuredate = #departuredate#
?
Maybe I don't understand what you are trying to do?
On 7/28/05, Doug Bedient [EMAIL PROTECTED] wrote:
I would still have dates between the arrival date and newly created departure
?
where thedate BETWEEN arrivaldate AND departuredate
?
-Original Message-
From: Doug Bedient [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 28, 2005 2:47 PM
To: CF-Talk
Subject: Re: Query Problem - Brain Cloud
I would still have dates between the arrival date and newly created
here's a timeline in days (if you don't have fixed-width font, CP
into something that does):
123456789
xxx reservation 1
xxx reservation 2
x reservation 3
q desired range
there are two possible days available: 4 and 6. That's the problem
he's trying to solve.
Then you need a reference table of dates, so you can query what IS NOT
there. You can hit this table like this:
select date
from datetable
where date BETWEEN x AND y
and date NOT IN (select distinct date from reservation where date
between x AND y)
right?
-jc
Barney Boisvert wrote:
Doug Bedient wrote:
I have 2 tables, one lists properties and the other contains arrival dates
and number of nights for those properties. The common variable is 'unitCode'.
The search parameters provide an arrival date and departure date.
My question. How would you use the arrival
I am using Flash remoting to send an array to a CFC - works fine, until
I try a query. I have been able to connect to the datasource and
retrieve values in another CFC with no problem. Why am I getting a
Error Executing Database Query error in Flash?
The part that I don't understand is how to
I am using Flash remoting to send an array to a CFC - works
fine, until I try a query. I have been able to connect to the
datasource and retrieve values in another CFC with no problem.
Why am I getting a Error Executing Database Query error in Flash?
The part that I don't understand
| icfconsulting.com
-Original Message-
From: Dave Watts [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 14, 2005 3:24 PM
To: CF-Talk
Subject: RE: Array access/query problem
I am using Flash remoting to send an array to a CFC - works
fine, until I try a query. I have been able
Thanks Dave!
Now I'm on to this: Any info on using Remoting to send complex data
types to a CFC?
i.e. From Flash:
myObj:Object = {data:[{count:23, title:Bananas}, {count:10,
title:Apples}]};
Jason Merrill | E-Learning Solutions | icfconsulting.com
NOTICE:
This message is for the
SELECT max(stockid) as stockid, data1, data2
FROM table
HAVING data1 = 5
Unfortunately this is returning the following data
StockID | Data1 | Data2
---
3 | 5 | 2
Ie: the correct stockid and data1 but data2 from a diferent row!
I have a problem I am sure is simple to solve but it has proved to be beyond
me.
Imagine I have the following data...
StockID | Data1 | Data2
---
1 | 1 | 2
2 | 3 | 4
3 | 5 | 6
And I want a query to return
StockID | Data1 | Data2
1 - 100 of 331 matches
Mail list logo