Re: CFQUERY where id = #valuelist(values from form scope)#

2007-07-06 Thread Christopher Jordan
How about: CFQUERY name=upd_vote_yes datasource=#datasource# update dbo.tbl_contest_2007 SET cb_vote1 = 1 WHERE cbcont_id IN (#ListQualify(Form.Vote,')#) /CFQUERY Cheers, Chris [EMAIL PROTECTED] wrote: All, Within a CFQUERY Valuelist works well when working with the query

Re: CFQUERY where id = #valuelist(values from form scope)#

2007-07-06 Thread J.J. Merrick
use cfqueryparam CFQUERY name=upd_vote_yes datasource=#datasource# update dbo.tbl_contest_2007 SET cb_vote1 = 1 WHERE cbcont_id IN (cfqueryparam value=#FORM.vote# list=yes cfsqltype=cf_sql_integer) /CFQUERY J.J. On 7/6/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: All, Within a CFQUERY

Re: CFQuery and MySQL

2007-07-02 Thread Tom King
This may help with the set up (but I'm assuming as it verifies it probably ok): http://www.oxalto.co.uk/index.cfm/2007/7/2/Setting-up-a-MySQL- database-with-Unicode--properly-in-Coldfusion-7 T On 2 Jul 2007, at 13:18, Mark Leder wrote: I have a new MySQL connection set up in CF7 - verifies

RE: CFQuery and MySQL

2007-07-02 Thread Mark Leder
That worked, thanks for clearing that up for me. -Original Message- From: Tom King [mailto:[EMAIL PROTECTED] Sent: Monday, July 02, 2007 8:40 AM To: CF-Talk Subject: Re: CFQuery and MySQL This may help with the set up (but I'm assuming as it verifies it probably ok): http

Re: CFQUERY vs SQL Server Stored Procedures

2007-03-23 Thread Robertson-Ravo, Neil (RX)
switchboard on +44 (0) 20 89107910. The opinions expressed within this communication are not necessarily those expressed by Reed Exhibitions. Visit our website at http://www.reedexpo.com -Original Message- From: Ryan, Terrence To: CF-Talk Sent: Fri Mar 23 02:13:36 2007 Subject: RE: CFQUERY

Re: CFQUERY vs SQL Server Stored Procedures

2007-03-23 Thread Teddy Payne
2007 Subject: RE: CFQUERY vs SQL Server Stored Procedures There are two reasons my organization encourages/forces all SQL to be in stored procedures. And they don't directly touch on performance. 1. A belief that keeping SQL code in the database is of itself a good thing. By keeping

Re: CFQUERY vs SQL Server Stored Procedures

2007-03-22 Thread simanonok
At 11:17 AM 3/20/2007, D wrote: Are cached queries as good as stored procedures? Technically which are better? Is it a significant difference? Cached queries hold data in RAM so no call to the DB is necessary, so they are always much faster than stored procedures (except for the first call to

RE: CFQUERY vs SQL Server Stored Procedures

2007-03-22 Thread Ryan, Terrence
There are two reasons my organization encourages/forces all SQL to be in stored procedures. And they don't directly touch on performance. 1. A belief that keeping SQL code in the database is of itself a good thing. By keeping the database interaction in the database you make it easier for DBA's

RE: CFQUERY vs SQL Server Stored Procedures

2007-03-20 Thread Robertson-Ravo, Neil (RX)
It all depends on what you want to do. For startersCached Queries are good but you cannot use cfqueryparam, SPs can return multiple recordsets which cfquery cannot. In some cases it may be better to use cfquery and in some an SP. -Original Message- From: [EMAIL PROTECTED]

RE: CFQUERY vs SQL Server Stored Procedures

2007-03-20 Thread Ian Skinner
Opinions? Are cached queries as good as stored procedures? Technically which are better? Is it a significant difference? Thanks If you are just using stored procedures to cache the data, it is probably a relatively even trade off. But, of course a stored procedure can do a lot more then just

Re: CFQUERY vs SQL Server Stored Procedures

2007-03-20 Thread coldfusion . developer
Thanks guys. I ijust found this article on Adobe.com that helped if anyone had similar questions to my original questions. http://www.adobe.com/devnet/coldfusion/articles/beg_storedproc.html D Opinions? Are cached queries as good as stored procedures? Technically which are better? Is it a

RE: Cfquery timeout parameter.

2007-02-22 Thread Ben Nadel
I guess it means the execution of a single: UPDATE SELECT DELETE Statement. Like, these would be TWO actions: UPDATE [table] set name = 'ben'; SELECT * FROM [table] .. Ben Nadel Certified Advanced ColdFusion MX7 Developer www.bennadel.com Need ColdFusion Help?

RE: Cfquery timeout parameter.

2007-02-22 Thread Ian Skinner
I guess it means the execution of a single: UPDATE SELECT DELETE Would this also apply to sub-selects and other more comlex SQL syntax? Say: SELECT aField FROM (SELECT bField FROM bTable) aTable Would that be two actions? Each one allowed to run for the timeout period, or if the inner select

RE: Cfquery timeout parameter.

2007-02-22 Thread Ben Nadel
] Sent: Thursday, February 22, 2007 12:52 PM To: CF-Talk Subject: RE: Cfquery timeout parameter. I guess it means the execution of a single: UPDATE SELECT DELETE Would this also apply to sub-selects and other more comlex SQL syntax? Say: SELECT aField FROM (SELECT bField FROM bTable) aTable

RE: CFQUERY: comma delimited list of id values

2006-11-29 Thread Ben Koshy
Try this: cfset results = valuelist(get_rec_4month.recipeID) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 29, 2006 7:38 PM To: CF-Talk Subject: CFQUERY: comma delimited list of id values All, I'm trying to figure out how best to pass a

RE: CFQUERY: comma delimited list of id values

2006-11-29 Thread Bobby Hartsfield
You could try a couple different ways... First you could use #valuelist(get_rec_4month.recipeID)# as the list Or you could just put the query that gets the recipeIDs in the IN () section of the final query like so... WHERE dbo.recipes.recipeID IN ( select recipeid from

RE: CFQUERY: comma delimited list of id values

2006-11-29 Thread Adrian Lynch
A few ways depending on what you need. Look at ValueList(). A very useful function. Or combine the first query in the second: cfquery name=sfc_all_recipes datasource=#recipes# SELECT *, dbo.recipeingredients.ingredients, dbo.addresses.firstname, dbo.addresses.lastname,

Re: CFQUERY: comma delimited list of id values

2006-11-29 Thread Jim Wright
[EMAIL PROTECTED] wrote: All, I'm trying to figure out how best to pass a list of comma delimited id (numeric) values to another query. I'm having trouble with getting the list of id values to not have a , (comma) after the last value in the output. Any help would be very appreciated.

Re: CFQUERY: comma delimited list of id values

2006-11-29 Thread Jochem van Dieten
coldfusion.developer wrote: I'm trying to figure out how best to pass a list of comma delimited id (numeric) values to another query. !--- 1 - GET RECIPES FOR PRE SELECTED MONTH AND YEAR --- CFquery name=get_rec_4month datasource=#datasource# select * from dbo.tbl_recipe_monthly_winner

RE: CFQUERY: comma delimited list of id values

2006-11-29 Thread Andy Matthews
ValueList would be the simplest means of doing what you need. cfquery name=myList SELECT id FROM tableName ORDER BY id /cfquery cfset idList = ValueList(queryName.column) !//-- andy matthews web developer certified advanced coldfusion programmer ICGLink, Inc. [EMAIL

Re: CFQuery - cfoutput - list of months and their year

2006-11-29 Thread Scott Weikert
if recw_assign_month is a date/time field - wouldn't sorting on this field straight up work fine? Seems like you're jumping through unnecessary hoops... ~| Introducing the Fusion Authority Quarterly Update. 80 pages of

Re: CFQUERY - Aggregate Function

2006-11-02 Thread Kris Jones
How about tek-tips.com? Can any recommend a free forum like houseoffusion for SQL coding issues. ~| Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting, up-to-date ColdFusion information by your peers,

Re: CFQUERY - Aggregate Function

2006-11-02 Thread Doug Brown
or http://www.sswug.org/ - Original Message - From: Kris Jones [EMAIL PROTECTED] To: CF-Talk cf-talk@houseoffusion.com Sent: Thursday, November 02, 2006 6:27 AM Subject: Re: CFQUERY - Aggregate Function How about tek-tips.com? Can any recommend a free forum like houseoffusion

RE: CFQUERY - Aggregate Function

2006-11-01 Thread Dave Watts
From the 2nd query, I'm trying to extract only records from 2nd query where the average of avg(ratingvalue) =4 and I'm not sure how do do this. HAVING AVG(ratingvalue) = 4 Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber

Re: CFQUERY - Aggregate Function

2006-11-01 Thread Ben Koshy
I'm not sure what SQL Platform you're using or what your schema exactly like... i can only infer based on your queries. If you're doing a Query of Query i don't think CF supports advanced functionality like HAVING... but in SQL it would be something like this: SELECT RecipeID,

RE: cfquery result

2006-10-19 Thread Turetsky, Seth
Don't need to do that...as it's already a structure. Just loop through it, ie: for (x=1; x LTE queryName.recordcount; x=x+1) queryName.columnName[x] -Original Message- From: Richard White [mailto:[EMAIL PROTECTED] Sent: Thursday, October 19, 2006 4:50 PM To: CF-Talk Subject:

Re: cfquery result

2006-10-19 Thread Teddy Payne
You can reference a query in cfscript: cfquery name=qryName select col1, col2 from /cfquery cfscript rownum = 0; while (row lt qryName.RecordCount) { rownum = IncrementValue(rownum); col1= qryName.col1[rownum]; col2 = qryName.col2[rownum]; } /cfscript On 10/19/06, Richard White

RE: cfquery result

2006-10-19 Thread Dave Watts
Hi, i hope this is a very simple question! but i want to be able to call a query but i want the result of the query to be stored in a structure format so that i can use in cfscript, the only examples i can find is if the result is used in a cfoutput queryqueryName/cfoutput tags. could

Re: cfquery result

2006-10-19 Thread Richard White
thats brilliant, thanks for all your advice ~| Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting, up-to-date ColdFusion information by your peers, delivered to your door four times a year.

Re: Cfquery in Javascript

2006-09-20 Thread Mullai Subbiah
Thank you very much for responding. Mullai ~| Introducing the Fusion Authority Quarterly Update. 80 pages of hard-hitting, up-to-date ColdFusion information by your peers, delivered to your door four times a year.

RE: cfquery sql= ...

2006-09-18 Thread James Smith
Where would that be? I don't see it in my local copy (CFMX). Is that an MX 7 path? Yeah, if you are running a single server install try the following three lines... cffile action=read file=C:\CFusionMX7\wwwroot\WEB-INF\cftags\META-INF\taglib.cftld variable=cftags cfset cftags =

Re: Cfquery in Javascript

2006-09-15 Thread Jake Churchill
Use Ajax. You can call a CF function with it which will perform the DB Query and return the results. Then call another CF function to populate form fields. Mullai Subbiah wrote: Can we use Cfquery within Javascript. I am trying to populate a form based on what I do within the Javascript.

RE: cfquery sql= ...

2006-09-14 Thread Richard Kroll
This is for multi configuration, for a single instance configuration, you can find it in \wwwroot\WEB-INF\cftags\META-INF\taglib.cftld Rich Kroll -Original Message- From: Andy Matthews [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 13, 2006 5:16 PM To: CF-Talk Subject: RE: cfquery

Re: cfquery sql= ...

2006-09-14 Thread Aaron Rouse
Our RAD tool here still uses this attribute in a couple of spots. Guess if it ain't broke, don't fix it. On 9/13/06, Claude Schneegans [EMAIL PROTECTED] wrote: cfquery datasource=dsn sql=insert into ... This is not spaghetti code, this vintage code ;-) --

re: Cfquery in Javascript

2006-09-14 Thread Bobby Hartsfiled
AJAX Return-Path: [EMAIL PROTECTED] Thu Sep 14 23:06:15 2006 Received: from houseoffusion.com [64.118.74.249] by mail.clickculture.com with SMTP; Thu, 14 Sep 2006 23:06:15 -0400 Received: from LOCALHOST by LOCALHOST with ESMTP id

Re: Cfquery in Javascript

2006-09-14 Thread Matt Williams
AJAX or, if the amount of data is minimal and not subject to change between requests, you could create javascript objects or arrays to hold the query data. Then when the form changes, the javascript changes the form fields. It's the same idea as two related select boxes, just expanding it to more

RE: cfquery sql= ...

2006-09-13 Thread Ben Nadel
I have never seen that before. Crazy! -b ... Ben Nadel www.bennadel.com Certified Advanced ColdFusion Developer Need Help? www.bennadel.com/ask-ben/ -Original Message- From: Nathan Strutz [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 13, 2006 4:27 PM To:

RE: cfquery sql= ...

2006-09-13 Thread Andy Matthews
According to CfQuickDocs, that is not currently an attribute: http://www.techfeed.net/cfQuickDocs/?getDoc=cfquery I wonder what would be the point of that? It'd sure make it harder to read your SQL and you couldn't use cfqueryparam. !//-- andy matthews web developer certified

re: cfquery sql= ...

2006-09-13 Thread Jeff Garza
You can have some fun looking for hidden functionality in CF by browsing the tag defs found in {jrun.installdir}\servers\cfusion\cfusion-ear\cfusion-war\WEB-INF\cftags\META-INF\taglib.cftld Lists out all of the known tags and available attributes for each... Might be surprised... CFANT

RE: cfquery sql= ...

2006-09-13 Thread Dan G. Switzer, II
Hey all, I just saw a code sample, and verified it on the livedocs, basically: cfquery datasource=dsn sql=insert into ... Since when did cfquery have a sql attribute, and is this deprecated or what? Maybe i'm just dense, but I've never seen it before. I actually believe this is a carry over

RE: cfquery sql= ...

2006-09-13 Thread Andy Matthews
Garza [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 13, 2006 3:50 PM To: CF-Talk Subject: re: cfquery sql= ... You can have some fun looking for hidden functionality in CF by browsing the tag defs found in {jrun.installdir}\servers\cfusion\cfusion-ear\cfusion-war\WEB-INF\cftags\MET A-INF

RE: cfquery sql= ...

2006-09-13 Thread Dan G. Switzer, II
I just saw a code sample, and verified it on the livedocs, basically: cfquery datasource=dsn sql=insert into ... Since when did cfquery have a sql attribute, and is this deprecated or what? Sure enough, I just found these docs on CF 1: http://docs.varda.nl/coldfusion/ch7b.htm#_Toc328065209

Re: cfquery sql= ...

2006-09-13 Thread Claude Schneegans
I actually believe this is a carry over from ColdFusion v1.x Confirmed. And I also remember that by that times, one could not reuse the same query name twice in the same template! A new query with the same name wouldn't overwrite the previous one. So can you imagine having a query in a loop,

Re: cfquery sql= ...

2006-09-13 Thread Claude Schneegans
cfquery datasource=dsn sql=insert into ... This is not spaghetti code, this vintage code ;-) -- ___ REUSE CODE! Use custom tags; See http://www.contentbox.com/claude/customtags/tagstore.cfm (Please send any spam to this address: [EMAIL PROTECTED]) Thanks.

RE: cfquery sql= ...

2006-09-13 Thread Jeff Garza
Yeah... it's for CF7 in the multi-server configuration. -- Jeff Original Message From: Andy Matthews [EMAIL PROTECTED] Sent: Wednesday, September 13, 2006 2:17 PM To: CF-Talk cf-talk@houseoffusion.com Subject: RE: cfquery sql= ... Where would that be? I don't see

RE: CFQUERY of non-swequential primary key ids

2006-08-23 Thread Ben Nadel
I am not sure why you are doing the second query... Why make the *randomization* more complicated than it has to be??? Simplify: !--- GET 2ND VALUE TO BE PASSED TO RANDRANGE --- CFQUERY name=get_vids_a datasource=#datasource# maxrows=1 select vidwee_id from vidweek /CFQUERY

RE: CFQUERY of non-swequential primary key ids

2006-08-23 Thread Everett, Al \(NIH/NIGMS\) [C]
How very inefficient. How about something like this: cfquery name=get_vid_ids datasource=#datasource# SELECT vidwee_id FROM vidweek /cfquery cfset idList=valueList(get_vid_ids.vidwee_id) cfset idPosition=randRange(1,listLen(idList),SHA1PRNG) cfset VAL_ID=listGetAt(idList,idPosition) CFQUERY

Re: CFQUERY of non-swequential primary key ids

2006-08-23 Thread Greg Morphis
You could query the table and get a list of the available IDs. Generate a random number between 1 and listlen() and then using ListGetAt() you can get that random ID and then query the DB again to pull back that record. On 8/23/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: All, I'm doing a

RE: CFQUERY of non-swequential primary key ids

2006-08-23 Thread Ben Nadel
Subject: RE: CFQUERY of non-swequential primary key ids How very inefficient. How about something like this: cfquery name=get_vid_ids datasource=#datasource# SELECT vidwee_id FROM vidweek /cfquery cfset idList=valueList(get_vid_ids.vidwee_id) cfset idPosition=randRange(1,listLen(idList

RE: cfquery: search numeric IN/Contains/Like

2006-08-21 Thread Snake
What is the value of #FORM.search# It must be at least 1 number, or a comma dleimited list of numbers. Contains requires full-text search and is for text fields. Snake -Original Message- From: Paul Ihrig [mailto:[EMAIL PROTECTED] Sent: 21 August 2006 21:34 To: CF-Talk Subject:

RE: cfquery: search numeric IN/Contains/Like

2006-08-21 Thread Ben Nadel
Paul, I am not sure if you want to get the subset to match in the DB or in the CF variable??? You could always loop over the WHERE items. SELECT * FROM [table] WHERE 1 = 0 cfloop index=i list=#FORM.search# OR CAST( ClientID AS VARCHAR(12)) LIKE

Re: cfquery: search numeric IN/Contains/Like

2006-08-21 Thread Paul Ihrig
the search field could be a first name, id date, whatever. i am doing the 0=0 to return all records if nothing is passed. then will check to see if it numeric, if it is they will be looking up an ID. if there is a similar id, return that set.. say our ids have 123456789 charecters. i just want to

Re: cfquery: search numeric IN/Contains/Like

2006-08-21 Thread Paul Ihrig
thanks Ben will try those examples in the mornning. On 8/21/06, Ben Nadel [EMAIL PROTECTED] wrote: Paul, I am not sure if you want to get the subset to match in the DB or in the CF variable??? You could always loop over the WHERE items. SELECT * FROM [table] WHERE

RE: cfquery - single quotes become doubled

2006-08-08 Thread Josh Adams
But note that using the render() function with untrusted data opens you up to CFML injection attacks so you'll need to sanitize for those. Josh -Original Message- From: David Carter [mailto:[EMAIL PROTECTED] Sent: Monday, August 07, 2006 4:34 PM To: CF-Talk Subject: Re: cfquery - single

Re: cfquery - single quotes become doubled

2006-08-07 Thread Charlie Griefer
#preserveSingleQuotes(sql_statement)# On 8/7/06, David Carter [EMAIL PROTECTED] wrote: Hello all, I am having a strange problem with a cfquery through SQL Server where I am building the SQL statement dynamically from form input. I wonder if anyone here has encountered and over come a

Re: cfquery - single quotes become doubled

2006-08-07 Thread Matt Williams
#PreserveSingleQuotes(sql_stmt)# On 8/7/06, David Carter [EMAIL PROTECTED] wrote: Hello all, I am having a strange problem with a cfquery through SQL Server where I am building the SQL statement dynamically from form input. I wonder if anyone here has encountered and over come a similar

RE: cfquery - single quotes become doubled

2006-08-07 Thread Everett, Al \(NIH/NIGMS\) [C]
That's by design. ColdFusion is escaping your single quotes. You need to either wrap your string in the PreserveSingleQuotes() function or, better, use cfqueryparam -Original Message- From: David Carter Sent: Monday, August 07, 2006 3:14 PM To: CF-Talk Subject: cfquery - single quotes

Re: cfquery - single quotes become doubled

2006-08-07 Thread David Carter
Thanks all, PreserveSingleQuotes() solved the problem. That's by design. ColdFusion is escaping your single quotes. You need to either wrap your string in the PreserveSingleQuotes() function or, better, use cfqueryparam ~|

RE: CFQuery simple but not working, strange

2006-06-15 Thread Ben Nadel
Maybe try this: 500 : select * 501 : from app_users 502 : where [UID] = cfqueryparam value=#URL.dupid# cfsqltype=CF_SQL_VARCHAR / 503 : /CFQUERY ... Ben Nadel Web Developer Nylon Technology 350 7th Avenue Floor 10 New York, NY 10001 212.691.1134 x 14 212.691.3477 fax

RE: CFQuery simple but not working, strange

2006-06-15 Thread Adkins, Randy
UID may be reserved but you can try: [UID] = #URL.dupid# -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, June 15, 2006 11:21 AM To: CF-Talk Subject: CFQuery simple but not working, strange Hey All, Argh! I've stared at this error for 10 minutes

Re: CFQuery simple but not working, strange

2006-06-15 Thread Claude Schneegans
SQLselect * from app_users where UID = cfoutput271/cfoutput Looks like you've got a CFOUTPUT tag in the SQL statement. Is it possible that url.id was transmited with this CFOUTPUT by some previous template? -- ___ REUSE CODE! Use custom tags; See

RE: cfquery group and flash remoting

2006-03-14 Thread Dave Watts
This maybe OT but I was wounder if its possible to group recordset for Flash remoting the way cf does with cfquery group. cfquery name=myQuery group=mainGroup h1#mainGroup.Title#/h1 cfoutput #subGroup.subTitle# /cfoutput /cfoutput No, I don't think so. When you use Flash

Re: cfquery and insert help needed

2006-03-10 Thread Rick Root
James Holmes wrote: Use cfqueryparm as should be done in every query. QFT. Get in the habit now before it's too late =) Rick ~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:235006 Archives:

RE: cfquery and insert help needed

2006-03-10 Thread Andy Matthews
QFT? !//-- andy matthews web developer ICGLink, Inc. [EMAIL PROTECTED] 615.370.1530 x737 --//- -Original Message- From: Rick Root [mailto:[EMAIL PROTECTED] Sent: Friday, March 10, 2006 8:38 AM To: CF-Talk Subject: Re: cfquery and insert help needed

Re: cfquery and insert help needed

2006-03-10 Thread Rick Root
Andy Matthews wrote: QFT? Quoted For Truth ~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:235026 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription:

Re: cfquery and insert help needed

2006-03-09 Thread Aaron Rouse
You need to double up that single quote within your string that you are inserting. Are you just doing this directly in the DB or through CF? If in CF, using a cfqueryparam should take care of this for you. If directly in the DB then change it to: insert into

Re: cfquery and insert help needed

2006-03-09 Thread S . Isaac Dealey
You need to double up that single quote within your string that you are inserting. Are you just doing this directly in the DB or through CF? If in CF, using a cfqueryparam should take care of this for you. If directly in the DB then change it to: insert into

Re: cfquery and insert help needed

2006-03-09 Thread S . Isaac Dealey
It's not dangerous if it's a hard-coded value... Otherwise, yes, use cfqueryparam Use cfqueryparm as should be done in every query. On 3/10/06, Charles Heizer [EMAIL PROTECTED] wrote: Hello, I'm trying to insert a value in to a column in oracle and I'm getting a missing comma error. I

Re: cfquery and insert help needed

2006-03-09 Thread Aaron Rouse
Nah, I was leaving it off to see if he was paying attention to my description of the fix and not just copy n pasting my solution. Ok, you are right, I missed that one. On 3/9/06, S. Isaac Dealey [EMAIL PROTECTED] wrote: You need to double up that single quote within your string that you

Re: cfquery and insert help needed

2006-03-09 Thread James Holmes
Sorry for abbreviating - as should be done in every query in which user input is used On 3/10/06, S. Isaac Dealey [EMAIL PROTECTED] wrote: It's not dangerous if it's a hard-coded value... Otherwise, yes, use cfqueryparam Use cfqueryparm as should be done in every query. -- CFAJAX docs and

RE: cfquery param vs cfif + N

2006-02-14 Thread Andy Matthews
With cfparam, you have built-in type checking. It also can help to avoid loads of cfif statements because you KNOW the variable is there, you just need to check it's value. !//-- andy matthews web developer ICGLink, Inc. [EMAIL PROTECTED] 615.370.1530 x737

Re: cfquery param vs cfif + N

2006-02-13 Thread Barney Boisvert
There is a theoretical performance gain, because the DB server can cache they query plan, and just plug in differing values for different queries. However, the more important benefit is SQL injection protection. To my knowledge the behaviour hasn't changed between 5 and 7, but I could be wrong.

RE: cfquery param vs cfif + N

2006-02-13 Thread Dave Watts
What is the difference of doing this: cfif getClient.saveAsUnicode eq 1N/cfif'#address#', over this: cfqueryparam value=#address# cfsqltype=cf_sql_varchar They're not comparable at all. The CFQUERYPARAM tag builds a prepared statement and uses a bind parameter for your value. Is there

Re: cfquery param vs cfif + N

2006-02-13 Thread Duncan
Thanks for the info so far guys, useful links too. I believe there is some sort of difference if you are using Unicode, but I havent been able to put my finger on it - any info on that side of things? On 2/14/06, Dave Watts [EMAIL PROTECTED] wrote: What is the difference of doing this:

RE: cfquery param vs cfif + N

2006-02-13 Thread Dave Watts
Thanks for the info so far guys, useful links too. I believe there is some sort of difference if you are using Unicode, but I havent been able to put my finger on it - any info on that side of things? Specifying Unicode hints simply tells the database to treat a string as a Unicode value.

RE: cfquery result=

2005-11-30 Thread Robertson-Ravo, Neil (RX)
It will fail in 6.1 - it is 7 only AFAIK. -Original Message- From: Ryan Guill [mailto:[EMAIL PROTECTED] Sent: 30 November 2005 14:11 To: CF-Talk Subject: cfquery result= This is probably a dumb question, but I'll ask just to make sure. Does someone have a 6.1 box they can test

RE: cfquery result=

2005-11-30 Thread Kerry
6.1 says: Attribute validation error for tag CFQUERY. The tag does not allow the attribute(s) RESULT -Original Message- From: Ryan Guill [mailto:[EMAIL PROTECTED] Sent: 30 November 2005 14:11 To: CF-Talk Subject: cfquery result= This is probably a dumb question, but I'll ask just to

Re: cfquery result=

2005-11-30 Thread Ryan Guill
Thats what I figured. Thanks for checking for me though. On 11/30/05, Kerry [EMAIL PROTECTED] wrote: 6.1 says: Attribute validation error for tag CFQUERY. The tag does not allow the attribute(s) RESULT -Original Message- From: Ryan Guill [mailto:[EMAIL PROTECTED] Sent: 30

RE: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Dave.Phillips
What database are you using (Access, SQL, Oracle, etc.). Also, can you SELECT PHONE# FROM TABLE1 ??? If so, then that's not your issue. If you can't SELECT PHONE#, try this: SELECT PHONE## FROM TABLE1 See if that works. Dave -Original Message- From: Perez, Percy [mailto:[EMAIL

Re: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Al Everett
You shouldn't ever use SELECT *. Name the columns you want. For the other, try PHONE##. On 7/20/05, Perez, Percy [EMAIL PROTECTED] wrote: Hello, I am having problems doing a simple SQL select. When I enter: SELECT * from TABLE1, I get an error message that the asterisk is an invalid

RE: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Perez, Percy
The database server is SQLBase by Gupta. I tried PHONE## and it works. Thanks, Percy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 20, 2005 10:50 AM To: CF-Talk Subject: RE: CFQuery and SQLBase - alternative to using asterisk What

RE: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Robertson-Ravo, Neil (RX)
That is a fairly loose statement... your shouldn't ever what if there is a need? There is not founding in you stating you shouldn't ever use it. -Original Message- From: Al Everett [mailto:[EMAIL PROTECTED] Sent: 20 July 2005 15:50 To: CF-Talk Subject: Re: CFQuery and SQLBase

RE: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Dave.Phillips
in the SELECT statement for ease of code reading and maximum efficiency. *Whew* Dave -Original Message- From: Robertson-Ravo, Neil (RX) [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 20, 2005 11:04 AM To: CF-Talk Subject: RE: CFQuery and SQLBase - alternative to using asterisk

Re: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Claude Schneegans
You shouldn't ever use SELECT *. Name the columns you want. Well, ... except if you do need all columns, and SELECT * is standard in SQL, especially for that purpose. ~| Find out how CFTicket can increase your company's

RE: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Robertson-Ravo, Neil (RX)
Yeah..maybe a little m ore clarification would have helped...but certainly to not use it all would be a tad harsh ;-) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 20 July 2005 16:23 To: CF-Talk Subject: RE: CFQuery and SQLBase - alternative to using

Re: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Al Everett
It's still sloppy. For one thing, there's no way to tell what columns you're getting back unless you look at the table as well. I find it very rare that I need all columns from any table. Any best practice document I've seen on SQL says to avoid SELECT *. On 7/20/05, Claude Schneegans [EMAIL

RE: CFQuery and SQLBase - alternative to using asterisk

2005-07-20 Thread Robertson-Ravo, Neil (RX)
will of course know what columns you are getting back - its normally your own database! And if you don't know it by now.;-) -Original Message- From: Al Everett [mailto:[EMAIL PROTECTED] Sent: 20 July 2005 16:41 To: CF-Talk Subject: Re: CFQuery and SQLBase - alternative to using

RE: cfquery crashes MySQL

2005-06-01 Thread Damien McKenna
Someone using my blog has reported that posting a comment crashes his MySQL server. You might suggest they update their JDBC drivers to the ones designed for MySQL 4. http://www.mysql.com/ has the gory. -- Damien McKenna - Web Developer - [EMAIL PROTECTED] The Limu Company -

Re: cfquery -- passing details of counts dynamically

2005-03-19 Thread Michael Traher
Hi Daniel, Not sure I fully understand. You have a form which the user can change, which, when submitted causes CF to run your query and generate some results in 'NumofIntake'. You are then displaying these. You can certainly use the 'onclick' attribute of some html tag to run some javascript

Re: cfquery -- passing details of counts dynamically

2005-03-19 Thread Daniel Kang
Mike, Yes, that is what I am trying to do, but here is the issue. Let's say #TheCount# (from the cfoutput below) returns 15 (meaning 15 cfquery results). cfoutput query=NumofIntakecfif NumofIntake.TheMonth eq 2 #TheCount#/cfif/cfoutput I want to see the details of 15 cfquery results when

Re: cfquery -- passing details of counts dynamically

2005-03-19 Thread Dave Francis
@houseoffusion.com Sent: Saturday, March 19, 2005 12:43 PM Subject: Re: cfquery -- passing details of counts dynamically Mike, Yes, that is what I am trying to do, but here is the issue. Let's say #TheCount# (from the cfoutput below) returns 15 (meaning 15 cfquery results). cfoutput query

Re: cfquery and maxrows attribute

2005-03-10 Thread Dave Carabetta
On Thu, 10 Mar 2005 09:50:37 -0500, Douglas Knudsen [EMAIL PROTECTED] wrote: ok, maybe I'm on some bad crack today, but I recall that the maxrows attribute of cfquery works AFTER the resultset is returned to CF from the DB. Is this the case for all RDBMs? I'm noticing that this is not the

Re: cfquery and maxrows attribute

2005-03-10 Thread Douglas Knudsen
check this SQL below out. We use it on Oracle 9i. Assuming you have the proper privs and all, you can see all the SQL running within the past few minutes. Add AND username = 'FOO' to see this for a single user. Using this SQL run a large cfquery using maxrows. You will see that maxrows is

Re: cfquery and maxrows attribute

2005-03-10 Thread Dave Carabetta
On Thu, 10 Mar 2005 10:57:09 -0500, Douglas Knudsen [EMAIL PROTECTED] wrote: check this SQL below out. We use it on Oracle 9i. Assuming you have the proper privs and all, you can see all the SQL running within the past few minutes. Add AND username = 'FOO' to see this for a single user.

Re: cfquery and maxrows attribute

2005-03-10 Thread Douglas Knudsen
ah, didn't think of that test. I just checked the debugging from CF on the query getdata (Datasource=aop_prod, Time=1671ms, Records=200) So CF is reporting only 200 rows also. I am convinced maxrows now actually dictates the maximum rows to the RDBMS. At least for Oracle and CFMX use. Others

Re: CFQUERY accessing MS SQL DB on another CF server

2005-03-07 Thread Adam Haskell
I might also add that if you are on a MX 7 Ent box this is a great example of how asynchronous cfm calls can really speed up an app. You can make an async call to a cfc which would do the remote update, no delays in your actual page rendering time and no try catch needed around the call. These

RE: CFQUERY accessing MS SQL DB on another CF server

2005-03-06 Thread Phillip B. Holmes
: Sunday, March 06, 2005 2:05 AM To: CF-Talk Subject: RE: CFQUERY accessing MS SQL DB on another CF server In fact, without sandboxing, it is trivial to write a CF template to get the raw code of everyone else's CF templates to get their usernames and passwords; since in this case the datasource is now

RE: CFQUERY accessing MS SQL DB on another CF server

2005-03-06 Thread James Holmes
, don't expect any security at all. -Original Message- From: James Holmes Sent: Sunday, 6 March 2005 3:19 To: CF-Talk Subject: RE: CFQUERY accessing MS SQL DB on another CF server Unless they are using sandboxing on CF Enterprise, like ay decent ISP should. -Original Message- From

Re: CFQUERY accessing MS SQL DB on another CF server

2005-03-06 Thread Claude Schneegans
it is trivial to write a CF template to get the raw code of everyone else's CF templates to get their usernames and passwords; It is at least as trivial (at least in CF 5) to write a CF template to get the CF administrator password, so storing the datasource password in it is not safe either.

RE: CFQUERY accessing MS SQL DB on another CF server

2005-03-06 Thread S . Isaac Dealey
not necessarily as black and white as it might seem. Unless they are using sandboxing on CF Enterprise, like ay decent ISP should. -Original Message- From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] Sent: Sunday, 6 March 2005 3:23 To: CF-Talk Subject: RE: CFQUERY accessing MS SQL DB

<    1   2   3   4   5   6   >