RE: dynamic query names

2004-06-19 Thread Pascal Peters
If the regular stuff is large, you can even do:

cfquery name=qFoo
select regular stuff
cfif something_is_true
	UNION select extra stuff I need 
(or maybe jus add to one or more clauses)
/cfif
/cfquery 

Depending on what you need to add it may be less readable than your
example. There could also be performance differences. But it is easier
to maintain.

Pascal

 -Original Message-
 From: Coleman, Brian [mailto:[EMAIL PROTECTED] 
 Sent: zaterdag 19 juni 2004 1:37
 To: CF-Talk
 Subject: RE: dynamic query names
 
 Ya know that does make sense :P
 
 It's the same exact thing without the union and adjusting the 
 is_true query with a few more lines of code
 
 I think I was using some faulty logic
 

 
 cfif something_is_true
 
cfquery name=qFoo
 
 select extra stuff I need
 
/cfquery
 
 cfelse
 
cfquery name=qFoo
 
 select regular stuff
 
/cfquery
 
 /cfif
 

 
 thanks
 

 

 
 -Original Message-
 From: Dave Watts [mailto:[EMAIL PROTECTED]
 Sent: Friday, June 18, 2004 6:18 PM
 To: CF-Talk
 Subject: RE: dynamic query names
 

 
  I have a general query set up for a page
  
  If certain parameters are not met, that query named, for example, 
  Query1 is used
  
  If the parameters are met, then a second query called Query2 is ran 
  and the contents of that Query are joined with a Union statement to 
  the first query and Query3 is produced. (so there's more 
 data on the 
  page)
  
  So in effect, either Query1 or Query3 is going to be the query that 
  will be used to produce the data on the page.
 
 You should be able to just use the same name again if you need to:
 
 cfquery name=qFoo ...
 ...
 /cfquery
 
 cfif something_is_true
 cfquery name=qBar ...
 ...
 /cfquery
 cfquery name=qBaz dbtype=query
 SELECT * FROM qFoo
 UNION
 SELECT * FROM qBar
 /cfquery
 cfset qFoo = qBaz
 /cfif
 
 cfoutput query=qFoo...
 
 But, honestly, there's probably a more efficient and simple 
 way to do whatever it is you're doing. Why not just run one 
 query or another, rather than one query and another, unless 
 they're in different (unlinkable) databases?
 
 Dave Watts, CTO, Fig Leaf Software
 http://www.figleaf.com/
 phone: 202-797-5496
 fax: 202-797-5444
 
_
 
 
 

 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Re: CFC Response Delay Bug in ColdFusion 6.1???

2004-06-19 Thread Carlo Gabriel Evidente
I'm very sorry for the duplicate postings...my internet was too slow that time and didn't know it was already posted...
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




RE: dynamic query names

2004-06-19 Thread Pascal Peters
variables[query].recordCount

If you are not on CFMX, you can create a struct to hold your variables
(lets call it vars) and use the same syntax

cfset vars = StructNew()
cfquery name=vars.query1 ...
...
cfset query = query1
...
#vars[query].reqordcount#

 
 For this I was thinking I need something like 
 #(#query#).recordcount# - but I can't get the syntax right

 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Verity index of dynamic and static pages

2004-06-19 Thread Ed Brown
I have what must be a common need which is to index a web site for searching where there is a mixture of web page types. There are approximatley 15 static pages, approximately 5 fully dynamic pages and the remainingpages are a mixture of static information combined with dynamic information pulled from a database.

For example a page may be a list of training courses with a short static introduction about how to identify training needs, then several course listings pulled from a database, followed by a short static summary of general available courses through colleges etc.

When I index this with Verity I get the CFM code being indexed and not the content of the dynamic pages.

I'm sure this is a trivial thing I'm verlooking as it is somethign that is so common it must be easily accomplished.

for other purposes I've used CFINDEX with a query for indexing a database of links and I've use CFINDEX with the directory option for static pages but it is the combination of both static and dynamic content in the same site that I'm having difficulty coping with.

Any help would be appreciated.
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Re: Kevin Roche is Lame

2004-06-19 Thread Philip Arnold
On Fri, 18 Jun 2004 16:25:53 -0400, Adrocknaphobia wrote:
 
 Is anyone else getting Spam Interceptor emails from this guy?
 
 (This message will probably trigger another one.)

I got one and promptly ignored it

I've seen cases of these things as harvesters, so I'm not trusting any
of them anymore
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Re: CFMX and JRUN

2004-06-19 Thread Adrocknaphobia
Well no offense to MM but there are alot better J2EE servers than
JRun. I don't think JRUN even falls in the top 10. It's right up there
in ease of use, but customization and complexity and support it
lagsfar behind.

But it does the job for me.. for now.

-Adam

- Original Message -
From: Dick Applebaum [EMAIL PROTECTED]
Date: Fri, 18 Jun 2004 16:18:04 -0700
Subject: Re: CFMX and JRUN
To: CF-Talk [EMAIL PROTECTED]

On Jun 18, 2004, at 2:36 PM, Ron Connelly wrote:

I took the plunge and made the purchase, and it has worked for my
purposes-- however not without much pain.Much of the process right
from the install has been difficult.And even getting help with the
install from MACR was tough.

Yes, MACR could learn from New Atlanta... they have a slick install , 
especially on the Mac.

Dick

In times like these, it helps to recall that
there have always been times like these.
- Paul Harvey -
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




OT - help in SQL query

2004-06-19 Thread Spectrum WebDesign
Hi

i'm looking for any help to do this query works fine

SELECT 
`groups`.`groupsDescr`,
`roles`.`roles_Agroup`,
`roles`.`rolesDescr`,
COUNT(`roles`.`rolesDescr`) AS TOTAL
FROM
`roles`
INNER JOIN `groups_roles` ON (`roles`.`rolesID` = `groups_roles`.`fkrolesID`)
INNER JOIN `groups` ON (`groups_roles`.`fkgroupsID` = `groups`.`groupsID`)
GROUP BY `roles`.`rolesDescr`
WHERE COUNT(`roles`.`rolesDescr`) GT 5

Using MySQL give me an error. how to do that?

Thanks for your time.

-- 
___
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Re: CFMX Updater 3 Link

2004-06-19 Thread Adrocknaphobia
Yeah those are the only ones I found. I;m going to give it shot, but
I'm quickly getting to the point of no return in terms of deadline. If
this doesnt work on Monday I have to begin to take everything out of
stored procedures and put everything inline.

:( there is nothing quite like the feeling of inheriting a spahgetti
code application thats mission critical.

-Adam

- Original Message -
From: Dave Watts [EMAIL PROTECTED]
Date: Fri, 18 Jun 2004 19:13:38 -0400
Subject: RE: CFMX Updater 3 Link
To: CF-Talk [EMAIL PROTECTED]

 This is the only one I see related to database drivers.

New database drivers:
http://download.macromedia.com/pub/coldfusion/drivers/3.3/macromedia_drivers
.zip

All CF hot fixes:
http://www.macromedia.com/support/coldfusion/ts/documents/tn17883.htm

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
phone: 202-797-5496
fax: 202-797-5444
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Re: OT - help in SQL query

2004-06-19 Thread Nick de Voil
 i'm looking for any help to do this query works fine

 SELECT
`groups`.`groupsDescr`,
`roles`.`roles_Agroup`,
`roles`.`rolesDescr`,
COUNT(`roles`.`rolesDescr`) AS TOTAL
 FROM
`roles`
INNER JOIN `groups_roles` ON (`roles`.`rolesID` =
`groups_roles`.`fkrolesID`)
INNER JOIN `groups` ON (`groups_roles`.`fkgroupsID` =
`groups`.`groupsID`)
 GROUP BY `roles`.`rolesDescr`
 WHERE COUNT(`roles`.`rolesDescr`) GT 5


 Using MySQL give me an error. how to do that?

All those backticks give me a headache  probably MySQL too.

GT isn't SQL, it's CFML.

Most importantly, you need to GROUP BY the columns that *aren't* referenced
in aggregate functions (eg COUNT), not the ones that are.

Nick
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Invalid data type for BIGINT...why?

2004-06-19 Thread Rick Faircloth
Why would this error code

Invalid data '13' for CFSQLTYPE 'CF_SQL_BIGINT'.
(13 refers to the Session.Subscriber_ID in the code below)

be sent for the following code?

CFLOOP Index=Newsletter_ID List=#Form.Newsletter_ID#
Delimiters=,

 CFQUERY Name=AddSubscription Datasource=#DSN#

Insert into subscriptions

 (Session.Subscriber_ID, Newsletter_ID)

Values (
cfqueryparam cfsqltype=CF_SQL_BIGINT
Value=CFOUTPUT#Session.Subscriber_ID#/CFOUTPUT,
cfqueryparam cfsqltype=CF_SQL_BIGINT
Value=CFOUTPUT#Newsletter_ID#/CFOUTPUT
 )

 /CFQUERY

/CFLOOP
--
Outgoing mail is certified Virus Free.
Checked by AVG Anti-Virus (http://www.grisoft.com).
Version: 7.0.251 / Virus Database: 263.3.3 - Release Date: 6/18/2004
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Re: Invalid data type for BIGINT...why?

2004-06-19 Thread Philip Arnold
Don't put CFOUTPUT inside the CFQUERYPARAM

On Sat, 19 Jun 2004 14:09:01 -0400, Rick Faircloth wrote:
 
 Why would this error code
 
 Invalid data '13' for CFSQLTYPE 'CF_SQL_BIGINT'.
 (13 refers to the Session.Subscriber_ID in the code below)
 
 be sent for the following code?
 
CFLOOP Index=Newsletter_ID List=#Form.Newsletter_ID#
 Delimiters=,
 
 CFQUERY Name=AddSubscription Datasource=#DSN#
 
Insert into subscriptions
 
 (Session.Subscriber_ID, Newsletter_ID)
 
Values (
cfqueryparam cfsqltype=CF_SQL_BIGINT
 Value=CFOUTPUT#Session.Subscriber_ID#/CFOUTPUT,
cfqueryparam cfsqltype=CF_SQL_BIGINT
 Value=CFOUTPUT#Newsletter_ID#/CFOUTPUT
 )
 
 /CFQUERY
 
/CFLOOP
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




RE: Invalid data type for BIGINT...why?

2004-06-19 Thread Rick Faircloth
That did it!Thanks, Philip.

I get so used to typing them into INPUT's that I sometimes
forget to leave them out...

Rick

-Original Message-
From: Philip Arnold [mailto:[EMAIL PROTECTED]
Sent: Saturday, June 19, 2004 2:04 PM
To: CF-Talk
Subject: Re: Invalid data type for BIGINT...why?

Don't put CFOUTPUT inside the CFQUERYPARAM

On Sat, 19 Jun 2004 14:09:01 -0400, Rick Faircloth wrote:

 Why would this error code

 Invalid data '13' for CFSQLTYPE 'CF_SQL_BIGINT'.
 (13 refers to the Session.Subscriber_ID in the code below)

 be sent for the following code?

CFLOOP Index=Newsletter_ID List=#Form.Newsletter_ID#
 Delimiters=,

 CFQUERY Name=AddSubscription Datasource=#DSN#

Insert into subscriptions

 (Session.Subscriber_ID, Newsletter_ID)

Values (
cfqueryparam cfsqltype=CF_SQL_BIGINT
 Value=CFOUTPUT#Session.Subscriber_ID#/CFOUTPUT,
cfqueryparam cfsqltype=CF_SQL_BIGINT
 Value=CFOUTPUT#Newsletter_ID#/CFOUTPUT
 )

 /CFQUERY

/CFLOOP
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Where do you get the Allaire.DocEx1.1 COM object?

2004-06-19 Thread Mark Elrod
I cannot find this example source anywhere?
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




Re: Where do you get the Allaire.DocEx1.1 COM object?

2004-06-19 Thread Doug White
http://livedocs.macromedia.com/coldfusion/6.1/htmldocs/tags-pb6.htm

==
Our Anti-spam solution works!!
http://www.clickdoug.com/mailfilter.cfm
For hosting solutions http://www.clickdoug.com
http://www.forta.com/cf/isp/isp.cfm?isp_id=1069
==

- Original Message - 
From: Mark Elrod
To: CF-Talk
Sent: Saturday, June 19, 2004 11:26 PM
Subject: Where do you get the Allaire.DocEx1.1 COM object?

I cannot find this example source anywhere?
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




cfmailparam

2004-06-19 Thread Taco Fleur
I am in need for some header that returns an undeliverable or out of
office message to two email addresses - I was thinking to just specify two
FROM addresses but does not seem to be valid.

 
Not sure what happens if I specify one in the FROM header and the other in
the REPLY-TO header?

 
I can't set up a list for this as one of the email addresses is dynamic.

 
Anyone?

 
Taco Fleur

Tell me and I will forget
Show me and I will remember
Teach me and I will learn
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]




list problem

2004-06-19 Thread Seamus Campbell
Hi

I have a list I'm trying to read with cffile

The list items sometimes have a binding code in the last field
and sometimes nothing. So its read as having either 7 or 8 fields.
So I'm trying to insert N/A in the last field when nothing is
there
===
AN^Apr04-^1^Bonyhady, Tim and Griffiths, Tom (eds.).^ Prehistory to
Politics: John Mulvaney, the Humanities and the Public
Intellectual. ^Mulvaney, one of Australia's best known
prehistorians, has been an influential figure in public debate and
public policy about world heritage, archaeological and
conservation practice, the function and operation of museums, and
the relevance of the humanities. * R.P. $32.95 now B$/B^7.95^
paper
AN^Apr04-^2^De Waal, Frans.^ The Ape and the Sushi Master: Cultural
Reflections by a Primatologist. ^The author examines the influence
of European ethology and Japanese primatology on the way in which
we regard other animals, the possibility of non-human culture
within the animal world, and our perceptions of the human race. *
R.P. $49.95 now B$/B^19.95^
AN^Apr04-^3^Elliott, Anthony.^ The Mourning of John Lennon.
^Examines the life, works, death and iconic status of this most
iconoclastic former Beatle, and discusses the psychology of
celebrity. * R.P. $27.95 now B$/B^7.95^ paper
AN^Apr04-^4^Frost, Ginger S.^ Promises Broken: Courtship, Class,
and Gender in Victorian England. ^The first part concentrates on
legal issues. The second part delves into the social issues of the
action - e.g. detailing the gender expectations that strongly
influenced the verdicts and reasons for broken engagements. The
third part explores various cultural ramifications for the action
among the elite. Reveals the nuances of courtship, marriage and
common law in Victorian England.R.P. $70.00 now
B$/B^14.95^
===
Records 1 and 3 have paper as the last field but 2 and 4 have
nothing .

Any ideas on how I can do this

Many thanks
Seamus

Seamus CampbellBoldacious WebDesign
http://www.boldacious.com[EMAIL PROTECTED]
ph 02 6297 4883mob 0410 609 267
 [Todays Threads] 
 [This Message] 
 [Subscription] 
 [Fast Unsubscribe] 
 [User Settings]
 [Donations and Support]