Re: debugging in cfscript

2012-02-09 Thread Rex

yes, but to call cf_abort, you want to do cf_abort()

It's like calling #now# instead of #now()#

- Rex

On 2/9/2012 5:46 AM, daniel kessler wrote:
>> you have cf_abort in your code instead of cf_abort()
> I am using cf_abort.
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:349851
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Hash function ignoring "." in username part of email address

2012-01-27 Thread Rex

Hi Eric,

Are you using a hash()?  Because that output looks look you are doing a 
URLEncodedFormat().

If you are doing a SHA hash, the result would a bunch of characters like 
"5BAA61E4C9B93F3F0682250B6CF8331B7EE68FD8"

If you are URLEncodedFormat() you'd get what you have: 
o%2Ew%2En%2Ee%2Er%40threeravensconsulting%2Ecom

Also, if you hash, the encoded email will have a different hash compared 
to the origina. non-encoded email.  The hash function is not smart at 
all, so you have to URLDecode() an encoded string.

- Rex

On 1/27/2012 1:28 PM, Eric Roberts wrote:
> We are on CF7 (yes I know...we are in the process of upgrading to 9...)
>
> I am having an issue that has just popped up recently.  when i have an
> email address with a "." in the username or multiple "."s like
> ow@threeravensconsulting.com or o.w.n@threeravensconsulting.com the
> has function is ignoring the 1st "." and encrypting the rest.  here's the
> code:  signature=hash(digest,"SHA", "UTF-8")
>
> So going with the second addy, here is the result:
> EMAIL=o.w%2En%2Ee%2Er%40threeravensconsulting%2Ecom&...
>
> as you can see, all of the "."s are escaped, with the exception of the
> first one...
>
> Odd thing is that this was working fine for the past few months.  We
> haven't done any updates or anything like that.  Any ideas as to why this
> is happening?  I am totally stumped on this one.
>
> If i try to hash an already escaped email addy...that would produce a
> different hash...correct?  Or is the hash function smart enough to
> recognize the escaped character?
>
> Thanks in advance.
>
> Eric
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:349656
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Programattically CREATE DATABASE in MySQL

2012-01-19 Thread Rex

I have something similar working so, maybe it's a permissions issue.  
Try the CREATE DATABASE AAA code with a DSN that's using the root user.  
Once you've confirmed it works, lock it down from there.

- Rex

On 1/19/2012 9:54 AM, HCI wrote:
> Hi all:
>
> I've been presented with an interesting problem for which I seem to have hit 
> a wall.  I have an app wherein it would be very handy to be able to have the 
> CF code create a new database as needed IN MySQL.  I've tried the straight 
> CREATE DATABASE AAA in a CFQUERY with an existing datasource and get an 
> exception error reading "Encountered "DATABASE" at line xxx".  I've tried 
> doing the entire SQL string as a variable.  I'm considering putting it in as 
> a stored proc on an existing database and passing in the new database 
> name...but nothing works.
>
> I saw an earlier thread here that seemed to allude to being able to do this 
> but with no specific examples.  Any help would be greatly appreciated.
>
> Thanks in advance!
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:349552
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Output columns from a query that have been formatted as 2 words

2011-11-06 Thread Rex

Sorry, disregard my answer, it has been answered already and my solution 
is incorrect

On 11/6/2011 12:41 PM, Rex wrote:
> I posted an answer to this in CF-Newbie, sorry for the cross-post.
>
> In the QoQ, wrap the column name in single-quotes.  Only tried in 
> CF9+MSSQL, but it works:
>
> 
> SELECT 'this is data in the column' AS [COLUMN WITH SPACES IN THE 
> NAME]
> 
>
> 
> SELECT 'COLUMN WITH SPACES IN THE NAME' AS COLUMNNAME FROM 
> storedProcData
> 
>
> 
> 
>
> - Rex

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:348489
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Output columns from a query that have been formatted as 2 words

2011-11-06 Thread Rex

I posted an answer to this in CF-Newbie, sorry for the cross-post.

In the QoQ, wrap the column name in single-quotes.  Only tried in 
CF9+MSSQL, but it works:


 SELECT 'this is data in the column' AS [COLUMN WITH SPACES IN THE NAME]



 SELECT 'COLUMN WITH SPACES IN THE NAME' AS COLUMNNAME FROM 
storedProcData





- Rex

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:348488
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: SHA-1 digest in CF7

2011-10-20 Thread Rex

Yep if you have SQL Server, you can have it create the SHA1 hash for 
you.  Sorry if high level, but I need to run.

- Rex

On 10/20/2011 11:33 AM, Eric Roberts wrote:
> I know that SHA-1 was not included in 7, but is there a way around
> this...possibly using a java method to create a hash.  An API we are using
> uses a SHA-1 hash digest and there is no choice in the encryption method.
> Any ideas?
>
> Eric
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:348283
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: coldfusion

2011-09-27 Thread Rex

Hi Greg,

If they have the same application name, CF will treat it as the same 
app.  The problem is that CF thinks it's a different session, because 
browsers use different cookies for different domains - you are using 
servera.org and serverb.org, so user1 may be logged onto servera.org 
with cookie x, then you are directed to serverb.org and are logged out 
with cookie y. If you are logged onto both domains then cookie x and y 
are both logged in; remember that CF keeps track of sessions via 
cookies.  If you have different cookies, it's like going onto the same 
server with different browsers.

You can implement something like OpenID but you will still need to 
log-in when switching servers, but you can use the same credentials.

The way I would do it, I would pass a use-once/short-expiration token 
when switching between domains that the receiving domain needs to 
authenticate against the domain that I am coming from.  This 
authentication should be server side, like via CFHTTP or checking the DB.

- Rex

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:347736
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Anyone know how to fix this or why this happening?

2011-08-30 Thread Rex

Sorry, just trying to help.  It's hard to pin down an intermittent 
problem like yours.

I've also had problems with GMail's SMTP and IMAP every now and then.  
Maybe you can benefit from a third party email service?

- Rex

On 8/30/2011 4:33 PM, Andrew Scott wrote:
> Rex,
>
> Nothing you said makes sense, nor is it a solution. I am very well aware
> that accounts have been migrating for Google Apps, that is not an issue and
> has never affected any of my other domains or emails at gmail. And it was
> one of the very first things I checked here.
>
> Secondly the user/password used for sending the email is verified
> succesfully in CF Admin, and as I stated emails are being sent. I thought it
> might have been a relay problem, so I did another test and that went ok.
>
> But for some reason certain emails being generated from the system are
> throwing the error that I posted, and I can't work out why some are being
> thrown in the undeliverable folder, and some are going through.
>
> Now Google searches have turned up nothing that helps, and most keep talking
> about a network congestion, but why is it so selective as to what goes
> through and what doesn't. Dragging the emails that can't be delivered into
> the spool, just seems to take forever to try to send them and they seem to
> be taking forever, before going straight back to the undeliverable folder
> again.
>
> So I am stumped, and have no idea where to begin looking for the problem any
> more.
>
>
> On Wed, Aug 31, 2011 at 9:20 AM, Rex  wrote:
>
>> Google can have availability problems sometimes.  Also, one of these
>> could be the reason:
>>
>> * They don't allow you to change the from address.  You must provide
>>   the proper username/password for the email to send.  You say that
>>   that is working, but I never got that to work, but I use a regular
>>   @gmail.com account, and not a google apps account
>> * Google has been migrating/updating google apps accounts, so maybe
>>   the admin got an email saying something like "Google Apps account
>>   transition complete" or something like that, so it may have
>>   affected something
>> * I think, before, we can just do username as the cfmail username
>>   attribute, without the "@gmail.com" and now I think you have to
>>   put this in (I'm not sure about this).
>> * Google has sending limits as well, make sure you have not hit those.
>>
>> - Rex
>>
>> On 8/30/2011 2:52 PM, Andrew Scott wrote:
>>> The other thing I should mention is that this has only just started
>>> happening as of 5 days ago, the site has been running for 8 years.
>>>
>>>
>>> On Wed, Aug 31, 2011 at 7:51 AM, Andrew Scott>> wrote:
>>>
>>>> I thought I would do a test and it appears to not be a relay issue, by
>>>> sending a dummy email from and to addresses that aren't the actualy smtp
>>>> account they were sent and received fine.
>>>>
>>>> All I can find on Google is that it might be a bottleneck, but then why
>>>> does some mail get through and some don't?
>>>>
>>>> Btw the smtp is a gmail account on Googel Apps.
>>>>
>>>> --
>>>>
>>> Regards,
>>> Andrew Scott
>>> WebSite: http://www.andyscott.id.au/
>>> Google+: http://plus.google.com/108193156965451149543
>>>
>>>
>>>
>>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:347148
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: PHP Serialization to JSON/Struct via ColdFusion?

2011-08-30 Thread Rex

maybe you can use this http://javaloader.riaforge.org/ that way you can 
drop the jar file in one of your directories

- Rex

On 8/30/2011 3:43 PM, Matthew Reinbold wrote:
> I have a database filled with PHP serialized strings that represent data that 
> I want to consume with a ColdFusion application (not pleased with the data 
> model for this project but, unfortunately, that ship sailed long before I 
> arrived).
>
> Sample data:
>
> a:18:{s:10:"user_title";s:0:"";s:31:"user_relationships_auto_approve";a:2:{i:1;i:0;i:2;i:0;}s:14:"picture_delete";i:0;s:14:"picture_upload";s:0:"";s:17:"messaging_default";s:10:"privatemsg";s:16:"privatemsg_allow";s:1:"1";s:28:"privatemsg_setmessage_notify";s:1:"1";s:20:"privatemsg_mailalert";s:1:"2";s:9:"init_stuff";s:3:"744";s:12:"current_stuff";i:623;s:7:"display";s:1:"1";s:10:"current_id";s:1:"4";s:7:"contact";i:0;s:12:"current_date";s:10:"1222790275";s:8:"nextpage";s:0:"";s:9:"messaging";s:0:"";s:5:"blahblah";s:10:"2145048145";s:11:"destination";s:26:"user/kaboom?";}
>
> I was hoping that there was a library or tag that would allow me to create a 
> ColdFusion variable out of this but I don't seem to be finding anything. I 
> did find this post:
>
> http://stackoverflow.com/questions/4511184/deserialize-php-array-in-coldfusion
>
> ...however adding Corfield's php scripting for ColdFusion project is a no-no 
> as I can't add jar files to the hosts CF lib folder.
>
> Anybody have an idea how I go about parsing a PHP Serialized variable and 
> turn it into something I can use via CF?
>
> - Matthew
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:347147
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Anyone know how to fix this or why this happening?

2011-08-30 Thread Rex

Google can have availability problems sometimes.  Also, one of these 
could be the reason:

* They don't allow you to change the from address.  You must provide
  the proper username/password for the email to send.  You say that
  that is working, but I never got that to work, but I use a regular
  @gmail.com account, and not a google apps account
* Google has been migrating/updating google apps accounts, so maybe
  the admin got an email saying something like "Google Apps account
  transition complete" or something like that, so it may have
  affected something
* I think, before, we can just do username as the cfmail username
  attribute, without the "@gmail.com" and now I think you have to
  put this in (I'm not sure about this).
* Google has sending limits as well, make sure you have not hit those.

- Rex

On 8/30/2011 2:52 PM, Andrew Scott wrote:
> The other thing I should mention is that this has only just started
> happening as of 5 days ago, the site has been running for 8 years.
>
>
> On Wed, Aug 31, 2011 at 7:51 AM, Andrew Scottwrote:
>
>> I thought I would do a test and it appears to not be a relay issue, by
>> sending a dummy email from and to addresses that aren't the actualy smtp
>> account they were sent and received fine.
>>
>> All I can find on Google is that it might be a bottleneck, but then why
>> does some mail get through and some don't?
>>
>> Btw the smtp is a gmail account on Googel Apps.
>>
>> --
>>
> Regards,
> Andrew Scott
> WebSite: http://www.andyscott.id.au/
> Google+: http://plus.google.com/108193156965451149543
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:347145
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: populate table from query results

2011-07-07 Thread Rex

One way is to use two DSNs, and create the INSERT once:


 select col1, col2 from table1



 INSERT INTO table2 (col1, col2) VALUES

 (#q1.col1#,  '#q1.col2#')
;,




 #q#


Something like that, HTH.

- Rex

On 7/7/2011 11:21 AM, Julie Davenport wrote:
> What is the fastest way to populate a table with the results of a query?  I 
> have a join query over 2 tables in database A and I need to insert all the 
> rows found into a table in database B.
>
> I cannot do it all in one query:
> insert into table3 (select ... from table1, table2...);
> because the tables are in different databases and postgresql does not allow 
> inter-db queries (and the cfquery datasource can only point to one database 
> at a time anyway).
>
> I'd like to use Coldfusion Query of Query to help but don't see how.  I 
> cannot query from the query results and insert into a table all in the same 
> cfquery (since a cfquery tag can have EITHER the datasource pointing to 
> database table is in, OR dbtype=query to do QofQ):
> insert into table3 (select * from myQuery);
>
> As a result, I have to do the query, then loop through the query results, and 
> each time through the loop, I insert a row of the results into the table.  
> This is very slow!  Is there a faster way with CF?
>
> Thanks!
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:346135
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: application.cfm

2011-06-22 Thread Rex

Hi Claude,

I agree to both Steven and Azadi's solution.

Sorry Claude, but yes, you will have to rewrite your system.  The 
"trick" you are using is a security risk.  Someone can rename a CFM file 
to a PDF file and upload it.  Now that CFM code can be executed on the 
server.

It shouldn't be that hard to do, since you are already serving up the 
PDF via cfcontent anyway.  Just change where you store your files.

- Rex

On 6/22/2011 8:47 AM, Azadi Saryev wrote:
> store your pdf files outside of web root so they are not directly
> accessible.
> serve them via an intermediary .cfm page, passing it the name of the pdf
> file, which checks user's access rights to requested pdf and serves the
> file or shows an error.
>
> Azadi
>
> On 22/06/2011 22:33 , =?ISO-8859-1?Q?Claude_Schn=E9egans wrote:
>> Hi,
>>
>> I've noticed that application.cfm is indeed run before the template called 
>> in the url, but the template itself is compiled BEFORE application.cfm is 
>> called.
>> I need to have the ability in application.cfm to run some code and NOT 
>> compile the template.
>>
>> Is it possible ?
>> CF 9
>>
>>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345536
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Applying hotFixes and updates

2011-06-17 Thread Rex

Hi Brook,

The CF 8.0.0 hotfix instructions says to only delete the following:

* hf800-1.jar
* hf800-2.jar
* hf800-70523.jar
* hf800-71471.jar
* hf800-73122.jar
* hf800-1875.jar
* hf800-77218.jar
* hf800-1878.jar

So leave everything else.

Also, looks like you applied the 8.0.0 fix (because you applied 
hf800-3.jar) but you are following the instructions for 8.0.1 
(because you said "You do not need to keep the ColdFusion 8.0.1 
cumulative hot fix JAR file after installing it with the ColdFusion 
Administrator"), so make sure you are using and reading the correct CF 
version.

Make sure you are applying the correct JARs, and deleting the JARs that 
it tells you to delete.

- Rex



~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345401
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF 32bit or 64bit

2011-06-14 Thread Rex

I just confirmed this.  Under Server Settings > Settings Summary > JVM 
Details, there is an item labeled "Java VM Name"

The 32 bit server will say: "Java HotSpot(TM) Server VM"
The 64 bit server will say: "Java HotSpot(TM) 64-Bit Server VM"

If you're saavy enough, you can launch a command line/terminal session, 
and go into your CF JVM, as indicated by the item labeled "Java Home" 
and run this command: "java -version"

It will say if it's 64-bit, and if it doesn't, it's 32-bit

- Rex

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345318
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF 32bit or 64bit

2011-06-14 Thread Rex

Hi Greg,

Under the JVM Details in the Settings Summary, it should say something 
that's 64-bit there.  If not, you are on 32-bit.

- Rex

On 6/14/2011 5:02 PM, Greg Morphis wrote:
> I'm running Windows Server 2008 and I'm not sure which version of CF was
> installed on the server, 32-bit or 64-bit.
> I've looked in the settings summary and I can't see. I tried to install the
> 9.0.1 64-bit updater and got some error "The ColdFusion 9 Application Server
> service could not be started.  Check the server "coldfusion" log files for
> more information."
> And then something about a specified file not being found. So I'm wondering
> if I installed the wrong version of the updater.
> Any ideas would be helpful! Thanks! I reverted back successfully by moving
> the files in the updater_backup back to the ColdFusion9 directory and the
> the files in the jre_preinstaller folder (I think that was the name...)
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345317
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Using LIKE in CF8

2011-06-01 Thread Rex

I think MSAccess only uses *, not %

On 6/1/2011 3:02 PM, Terry Troxel wrote:
> I have been doing this forever with no problems until today.
> Can anyone spot my error(s)?:
>
> 
>   select * from leads where 0 = 0
>   
>and lastname LIKE '#lname#%'
>   
> 
>
> which give me this error:
> Error Executing Database Query.  [Macromedia][SequeLink JDBC Driver][ODBC
> Socket][Microsoft][ODBC Microsoft Access Driver] Too few parameters.
> Expected 1.
>The error occurred in *C:\Inetpub\wwwroot\RNC\lmain.cfm: line 13*
>
> 11 :  select * from leads where 0 = 0
> 12 :  *13 :and lastname LIKE '#lname#%'*
> 14 :  
> 15 :
>
>   --
> SQLSTATE   07002 SQLselect * from leads where 0 = 0 and lastname LIKE
> 'tro%'  VENDORERRORCODE   -3010 DATASOURCE   rnc
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:345038
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: The vagaries of QueryNew

2011-03-23 Thread rex

Hi Kevin,

You must be doubling up a call to QueryAddRow().  Go do a search on 
github.com for a piece of code called QuerySim by Hal Helms.  It'll help 
you create queries you need, and it's very easy to use.

- Rex

On 3/23/2011 5:01 AM, Steven Durette wrote:
> First, let me say that anything that can be done in the database should be. 
> But, if you must do it this way, why don't you have the db return the extra 
> columns as nulls then set the cell values. That way you don't have the extra 
> query object being built.
>
> Steve
>

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:343228
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: To Fusionreactor or not to Fusionreactor

2011-03-10 Thread rex

Have you tried SeeFusion for your server monitoring needs?  It's very 
lightweight.

On 3/10/2011 9:16 AM, Bobby Hartsfield wrote:
> Thanks again Steve. It looks like a good read. Hopefully, I will be able to
> wear them down if not convince them :-)
>
> On a side, we also had Mike Brunt help with some JVM performance tuning. I
> don't guess I need to tell you what a good choice that was. :-)
>
> .:.:.:.:.:.:.:.:.:.:.:.:.:.
> Bobby Hartsfield
> http://acoderslife.com
> http://cf4em.com
>
>
> -Original Message-
> From: Steve 'Cutter' Blades [mailto:cold.fus...@cutterscrossing.com]
> Sent: Thursday, March 10, 2011 6:34 AM
> To: cf-talk
> Subject: Re: To Fusionreactor or not to Fusionreactor
>
>
> Bobby,
>
> This post will give you some insight on the environment, and it's
> challenges:
>
> http://blog.cutterscrossing.com/index.cfm/2008/6/22/Build-Applications-That-
> Scale
>
> As for settings and production...We didn't really run into any
> showstoppers. We pushed it to give us a lot of info (AMF introspection,
> db transaction logging, etc) and it was consistently our lifesaver. Paid
> for itself within 10 min of install (without it, it would've taken days
> to figure out what was going on), and time and time again. Once we were
> hit with a SQL injection attack (way legacy code). FR helped us discover
> who and how in minutes, and we were able to reverse engineer the attack
> and  recover in short order (Mike Brunt was in, on contract, to help us
> with JVM tuning that day and got to witness all of that, it was pretty
> impressive how quick we got to react on that).
>
> Steve 'Cutter' Blades
> Adobe Certified Expert
> Advanced Macromedia ColdFusion MX 7 Developer
> 
> http://blog.cutterscrossing.com
>
>
> Co-Author "Learning Ext JS 3.2" Packt Publishing 2010
> https://www.packtpub.com/learning-ext-js-3-2-for-building-dynamic-desktop-st
> yle-user-interfaces/book
>
> "The best way to predict the future is to help create it"
>
>
> On 3/9/2011 4:47 PM, Bobby Hartsfield wrote:
>> Thanks Steve. I remember when the guys were demo-ing FR at Cfunited a few
>> years ago. It definitely stole the show (at least on the vendor floor). I
>> loved the depth of it and miss it a lot... especially now that we have a
>> ghost in the machine that no logs are really pointing us to.
>>
>> I'd love to hear more about the environment you use it in and whether or
> not
>> you know of any known FR conjurations or settings that might not be
> suitable
>> for production environments.
>>
>> .:.:.:.:.:.:.:.:.:.:.:.:.:.
>> Bobby Hartsfield
>> http://acoderslife.com
>> http://cf4em.com
>>
>> -Original Message-
>> From: Steve 'Cutter' Blades [mailto:cold.fus...@cutterscrossing.com]
>> Sent: Wednesday, March 09, 2011 4:44 PM
>> To: cf-talk
>> Subject: Re: To Fusionreactor or not to Fusionreactor
>>
>>
>> No time now, and you can ping me off list, but I'll tell you FR is
>> fantastic, highly critical in a heavy load environment, and it was a
>> standing order with my previous team that whenever a server is purchased
>> that FR is always part of the quote and budget process.
>>
>> Steve 'Cutter' Blades
>> Adobe Certified Expert
>> Advanced Macromedia ColdFusion MX 7 Developer
>> 
>> http://blog.cutterscrossing.com
>>
>>
>> Co-Author "Learning Ext JS 3.2" Packt Publishing 2010
>>
> https://www.packtpub.com/learning-ext-js-3-2-for-building-dynamic-desktop-st
>> yle-user-interfaces/book
>>
>> "The best way to predict the future is to help create it"
>>
>>
>> On 3/9/2011 2:43 PM, Bobby Hartsfield wrote:
>>> All,
>>>
>>> I'd like to hear from some of you that might be running FusionReactor in
>>> HEAVY load production environments. I'd especially like to know if you
>> have
>>> compared server performance statistics with and without Fusionreactor
>>> installed to measure its true overhead in your setup.
>>>
>>> We have a very high traffic CF application that runs on many load
> balanced
>>> CF8 Enterprise servers. (we've had to reassure adobe reps that the
> numbers
>>> we are reporting are correct when they ask about traffic... it's quite
>>> funny)
>>>
>>> At one point, we invested in Fusionreactor (many copies of it) and
>> installed
>>> it on our servers. It quickly helped us work through a performance issue
>> we
>>> were having (Charlie Arehart actually helped us track it down through
>>> FusionReactor)... and as far as I was concerned, that made it all worth
>> it.
>>> However, we eventually started seeing some spikes that IT deemed the
>> result
>>> of having FusionReactor installed. I'll have to admit that performance
> did
>>> SEEM to get better without it installed... but I think it might have just
>>> been the "whole out of sight, out of mind" mentality. We no longer had a
>>> bird's eye view into what was actually happening in real time so everyone
>>> thought it was "better". Besides, too many people swear by FR for it to
>> have
>>> any real noticeable overhead... right?
>>>
>>> I'd like to 

Re: Database connection cross over

2011-02-10 Thread rex

Never happened to me.  I think this setup is very common (having a 
single SQLSERVER, and creating multiple DSNs to different databases), 
someone would have run into it.

Try dumping SELECT @@SERVERNAME, DB_NAME() to see if you really are 
connected to the correct DB

Do you have code that do USE Banana that switches 
your database from Apple to Banana?  Once you switch, and CF reuses that 
connection you will be on that database.

Try using the same DSN settings (username, password, database) in SQL 
Server Management Studio and see if you get the same issue.

Do your DSNs use different user accounts? Make sure they're pointing to 
the correct ones.


On 2/10/2011 10:03 AM, Matt Williams wrote:
> Basics: Windows 2003 server, CF 7.0.2, SQL Server 8
>
> Multiple datasources, but lets specifically look at the ones named Apple and 
> Banana. They point to separate databases on the same SQL server, connecting 
> to db Apple and db Banana respectively, as expected. However, occasionally, 
> datasource Apple gets mixed up and attempts to use db Banana.
>
> At first my error reported the following:
> Datasource: Apple
> Detail: [Macromedia][SQLServer JDBC Driver][SQLServer]Invalid object name 
> 'dbo.company'.
>
> After verifying the table did indeed exist, I did a simple cfquery to return 
> the tables that do exist in datasource Apple. This query returned the tables 
> from database Banana! I double and triple checked the datasource in the CF 
> Administrator. It is correctly set to Apple.
>
> This is happening on our dev server. My solution thus far has been to create 
> a new datasource called Apple_tmp. It seems to work. I did try to then delete 
> Apple and rename Apple_tmp back to Apple, but it soon had the same issue. 
> A!
>
> My suspicions are some DNS or IP funkiness but have yet to track that down. 
> This is all on one physical box, so I don't know if that would be it or not. 
> I'm mainly curious if anyone else has seen this.
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:342123
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: coldfusion errors

2011-02-08 Thread rex

The site-wide error handler in CFAdmin should catch all errors, even 
compile-time errors (a syntax error, in this case).  The problem is if 
your site-wide error handler has an error in there, then you're out of 
luck.  It's a good idea to have your site-wide handler to be just a 
static file, or a very basic file that should avoid erroring out.  
Common errors that happen on the site-wide error handler is when 
referencing error variables, because they don't exist for all error 
types (like error.message)

Ray Camden has a very good article and very long discussion on Error 
Handling at 
http://www.coldfusionjedi.com/index.cfm/2007/12/5/The-Complete-Guide-to-Adding-Error-Handling-to-Your-ColdFusion-Application

That CF livedoc link that Charlie Griefer sent should be required 
reading for everyone, and has a lot of information on handling errors.


On 2/8/2011 6:58 PM, Brian Cain wrote:
> Error handling is for run time errors. Your second example is a compile 
> error. You cannot use error handling to fix this. You could try a site wide 
> error handler, but that probably won't work either.
>
> Brian Cain
>
> Sent from my iPhone
>
> On Feb 8, 2011, at 7:30 PM, Richard  Steele  wrote:
>
>> Is there anyway to catch coldfusion programming errors?
>>
>> #999sdflkjsdf;lk#  is caught by my error handler.
>>
>> But#alsdk;fjlkj#> is not.
>>
>> Thanks in advance.
>>
>>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:342039
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Math weirdness

2011-02-03 Thread rex

These are the pitfalls of a dynamically typed language, and FLOAT/INT 
conversions.

Your number1 is a string, number2 is a Double, and your number 3 is a 
string:


number3 is #number3.getClass().getName()#
number2 is #number2.getClass().getName()#
number1 is #number1.getClass().getName()#


If you do val() they will equal out:

Number3 equals number2
Number3 does NOT equal number2

 From http://docs.sun.com/source/806-3568/ncg_goldberg.html#680, "the 
result of a floating-point calculation must often be rounded in order to 
fit back into its finite representation. This rounding error is the 
characteristic feature of floating-point computation."

Checkout this code:


 #(0.1 * 0.1) EQ 0.01# 
 #0.1 * 0.1# 
 #javacast("bigDecimal", 0.1 * 0.1)# 


If you need strict computation, stick to Doubles or bigDecimals all the 
time, and don't rely on implicit conversions.

Also this is not a CF thing or a Java thing, other languages plague this 
too i.e Python (for division, 3/4 is different from 3.0/4.0) and .NET 
(http://stefanoricciardi.com/2010/03/02/comparing-floating-point-numbers/), 
and PHP 
(http://it.slashdot.org/story/11/01/06/1820208/PHP-Floating-Point-Bug-Crashes-Servers
 

 
or just start typing in google instant, php floating... and you'll see 
all the suggestions hehe)

On 2/3/2011 12:56 PM, Jen McVicker wrote:
> number1 (evaluate(12.5 * 1.1)): 13.75
> number2 (12.5 * 1.1): 13.75
> number3 (13.75): 13.75
> 13.75 - 13.75: 0
> 13.75 - 13.75: -1.7763568394E-015
> Number3 equals number1
> Number3 does NOT equal number2
>
>
>
> Obviously number2 is set to a reference of the expression rather than the
> actual value that is returned.  But since the variable outputs as 13.75, why
> does it make a difference?  Can someone explain it to me in small words so
> that I will understand?  ;-)
>
>
>
> Jen Perkins McVicker
> Adobe Certified ColdFusion Developer
> Email: jen.mcvic...@gmail.com
>
> Linked In: http://www.linkedin.com/in/jmcvicker
>
>
>
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:341853
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Exporting query data

2011-02-02 Thread rex

John's answer is the correct one for doing it on the CF server side.

Here's how I would do it on the SQL server side.  For MySQL:

SELECT * INTO OUTFILE '/location/of/file.csv'
FIELDS TERMINATED BY ','
OPTIONALLY ENCLOSED BY '"'
LINES TERMINATED BY '\n'
FROM AnyTable

For MSSQL, it can be simple or complicated:

simple:
 1.  Run your query in SQL Server Management Studio
 2.  Highlight the resultset
 3.  Copy/paste into excel
 4.  Save as CSV

complicated, run BCP command line utility on the SQL Server:

c:\>bcp DatabaseName.dbo.TableName out C:\fileLocation.csv -c -t "," -S 
SERVERNAME -U username -P password

Have fun!


On 2/2/2011 11:43 AM, John M Bliss wrote:
> http://cflib.org/udf/QueryToCsv
>
> On Wed, Feb 2, 2011 at 1:31 PM, Richard Steele  wrote:
>
>> Is there an easy way to export SQL query data into a tab delimited or CSV
>> format? I know I can do this with a loop and variables, but it seems like
>> there should be an easier way. (my query has 100+ column names!). Thanks in
>> advance.
>>
>>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:341820
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Subtracting two dates

2011-01-28 Thread rex

As Charlie and Brian have pointed out, you can use that on the CF side.

You can also do on the SQL side, so since you are presumably getting 
cprAdultExp from a query anyway, it'll save some processing cycles hehe

SELECT cprAdultExp, DATEDIFF(DAY, cprAdultExp, GETDATE()) AS 
NumberOfDaysInBetween FROM tableX


On 1/28/2011 10:55 AM, Charlie Griefer wrote:
> On Fri, Jan 28, 2011 at 11:45 AM, Adam Bourg  wrote:
>> I'm trying to figure out how to subtract two dates and return the number of 
>> days between then.
>>
>> My dates are cprAdultExp, which is a database column, I typically write it 
>> as: #dateformat(cprAdultExp,"mm/dd/")#
>>
>> The other is Now()
>> Which I also format as: #dateformat(Now(),"mm/dd/")#
>>
>> What's the easy way to do this?
> http://www.cfquickdocs.com/cf9/#datediff
>

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:341653
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: why is cf_builder so expensive?

2011-01-27 Thread rex

I hope this is funny for you guys because it was funny for me

http://www.youtube.com/watch?v=GwzklHZqkbE

Ballmer seems like a nice guy.  It wasn't an iPhone, so he didn't smash 
it ;-)


On 1/27/2011 10:14 PM, Mike Chabot wrote:
> products. The CEO of Coca-Cola will never be seen enjoying a Pepsi. Steve
> Balmer will never be seen talking on an iPhone. If someone handed him one he
> would smash it on the ground as quickly and as forcefully as he could. Adobe
> appears to lack the same internal pressure and competitive spirit that
>

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:341609
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF 8.01 Services freezing up

2010-12-22 Thread rex

In CFAdmin, if I go into SERVER SETTINGS > Settings Summary, in the 
Database Data Sources section, it lists all my data sources.  So, if I 
see everything using a JDBC URL, does that mean that I don't use ODBC 
data sources?

On 12/22/2010 3:51 PM, Dave Watts wrote:
>> If you have checked "Maintain connections across client requests", stopping
>> ColdFusion 8 ODBC Server shuts down the websites?
>>
>> I had some sites stop working while others didn't. After investigating their
>> datasource settings, this is what I found.
> Are you sure you're not using any ODBC data sources? Maybe it would be
> a good idea to list explicitly what database drivers you're using for
> each data source.
>
>> So, do you recommend removing the selection for all websites and turning off
>> ODBC Server?
> I would generally not recommend unchecking that option in production,
> as it'll make things slower and less efficient. But if shutting it off
> keeps your server from crashing, go ahead and shut it off.
>
> I'd recommend turning off the two ODBC services if you're not using
> them. But make sure you're not using them.
>
> Dave Watts, CTO, Fig Leaf Software
> http://www.figleaf.com/
> http://training.figleaf.com/
>
> Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on
> GSA Schedule, and provides the highest caliber vendor-authorized
> instruction at our training centers, online, or onsite.
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:340228
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF9 Not Restarting after Java Update

2010-12-14 Thread rex

Maybe that's a JDK installed with the public JRE?

On 12/14/2010 9:33 AM, Chad Baloga wrote:
>> If you go to the JVM shown in the CF Administrator, does it have a
>> server DLL?
> This is on dev with CF9 multi instance:
>
> Server Product ColdFusion
> Version   9,0,1,274733
> Edition   Enterprise
> Serial Number ***
> Operating System  Windows 2003
> OS Version5.2
> Update Level  
> /C:/ColdFusion9/servers/cfusion/cfusion-ear/cfusion-war/WEB-INF/cfusion/lib/updates/chf9010001.jar
> Adobe Driver Version  4.0 (Build 0005)
> JVM Details
> Java Version  1.6.0_22
> Java Vendor   Sun Microsystems Inc.
> Java Vendor URL   http://java.sun.com/
> Java Home C:\Program Files\Java\jre6
> Java File EncodingCp1252
> Java Default Locale   en_US
> File Separator\
> Path Separator;
> Line SeparatorChr(13)
> User Name SYSTEM
> User Home C:\Documents and Settings\Default User
> User Dir  C:\ColdFusion9\bin
> Java VM Specification Version 1.0
> Java VM Specification Vendor  Sun Microsystems Inc.
> Java VM Specification NameJava Virtual Machine Specification
> Java VM Version   17.1-b03
> Java VM VendorSun Microsystems Inc.
> Java VM Name  Java HotSpot(TM) 64-Bit Server VM
> Java Specification Version1.6
> Java Specification Vendor Sun Microsystems Inc.
> Java Specification Name   Java Platform API Specification
> Java Class Version50.0
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:340056
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: ms sql stored procedure call returns columns in different order?

2010-12-08 Thread rex

query.getColumnNames() should be able to get your columns in the 
original order

I can see some cases where the original order is needed, like when 
outputting dynamic SQL and you want to preserve the column order, i.e. 
in a SQL client app.

On 12/8/2010 1:48 PM, Janet Whittredge wrote:
> I call a stored procedure in  and the result set returned has all of 
> the
> data the stored procedure generated, but, the column order is changed to 
> alphabetical order. Why is the resultset changed?  Is there any way to get 
> the data back as it was generated in the stored procedure?   ColdFusion 8, MS 
> SQL Server 2005, Windows Server 2003
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:339929
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF9 + == Log Every Request?!?!

2010-11-30 Thread rex

In CFAdmin, go to DEBUGGING & LOGGING > Log Files

There should be a STOP button that disables the logging for that.  I 
haven't tried it but let me know if that works.  Thanks!

On 11/30/2010 9:17 AM, Matt Quackenbush wrote:
> Just moved an application from CF8 to CF9.  This particular application has
> hundreds of  requests.  After the move, suddenly every single one of
> them is being logged.  I have looked everywhere I can think to look to try
> and find a setting for this, but to no avail.
>
> Any idea how I can turn this logging off?
>
> Thanks in advance.
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:339635
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CFMail 'from' seems to get ignored

2010-11-19 Thread rex

Google's mail servers do not allow you to spoof the "FROM" email 
address.  It will always come from the authenticated account.

i.e.  If I'm using google's mail servers, and login as 
thisper...@gmail.com, I cannot send from thatper...@gmail.com or 
anotherper...@site.com

Stefan Richter wrote:
> Hi all,
> I've configured mail in CF Admin using smtp.gmail.com with my personal GMail 
> account details (username and password). Mail is being sent without problems. 
>
> However users of one of the websites where I use the CFMAIL tag and a 'from' 
> address of i...@site.com tell me that the email arrives as having been sent 
> from me, using my GMail address. What am I missing? Shouldn't the 'from' in 
> CFMail take priority? That's what I seem to remember always happened when I 
> used my own SMTP server in the past.
>
> BTW I am not specifying server details or credentials in the CFMail tag 
> itself, they are only specified in CFadmin.
>
> Cheers 
>
> Stefan
>
>
>
>
>
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:339404
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: index.cfm being hacked

2010-11-18 Thread rex

You store the hash (i.e. hash("index.cfm")) of the cfm file somewhere: 
in another file, or in a table, etc. and check intermittently, like once 
a day or hour.  So, a job that checks for the MD5SUM of the files, and 
maybe a database table that stores the files and the hashes.

Awesome thing would be an ant script that during deployment 
populates/updates a database table with all your files (or changed 
files) and their MD5 hash, and then deploys the files.  Or maybe just a 
couple of important files to watch, like Application.cfc, index.cfm, com 
directory, etc.

Or do you guys think that's overboard? 

Mike Little wrote:
> hi al, i would be interested to know how you went about having your computer 
> check the index pages for changes? sounds kinda useful.
>
> mike 
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:339393
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF QR Code Generator

2010-11-17 Thread rex

How about google charts?  
http://code.google.com/apis/chart/docs/gallery/qr_codes.html

Here's a sample: 
http://chart.apis.google.com/chart?cht=qr&chd=t:60,40&chs=250x100&chl=coldfusion%20rocks
 




Robert Harrison wrote:
> Just curious, has anyone seen any CFCs or CF code snippets for generating a 
> QR code?
>
>
>
> Robert B. Harrison
> Director of Interactive Services
> Austin & Williams
> 125 Kennedy Drive, Suite 100 
> Hauppauge NY 11788
> P : 631.231.6600 Ext. 119 
> F : 631.434.7022
> http://www.austin-williams.com 
>
> Great advertising can't be either/or.  It must be &.
>
> Plug in to our blog: A&W Unplugged
> http://www.austin-williams.com/unplugged
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:339331
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


cf8, flex and mxml files

2010-11-13 Thread rex

I have CF8.0.1, and when I request an mxml file, it compiles to a 
actionscript/swf a la FLEX, and I get the flash file.

When I have a missing CFM file, I get a 404.

But, when I have a missing MXML file, I get a 500 server error, and I 
get an error message that displays the full system path:


--
Compilation Results

Errors, warnings or exceptions were found while compiling 
/yyy/zzz/xxx/webroot/sss.mxml. Visit the online Flex documentation or 
API reference for further information.



1 Exception found.

Exception java.io.FileNotFoundException
File not found: /yyy/zzz/xxx/webroot/sss.mxml

---

How do I make it generate a friendly 404 error, or at least not show the 
system path?

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:339184
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF 9 Enterprise Create New Instance

2010-11-01 Thread rex

These links may help:
http://www.adobe.com/devnet/coldfusion/articles/clustering_cf8.html
http://www.placona.co.uk/148/coldfusion/creating-new-coldfusion-8-instances-the-easy-way/

Dawn Sekel wrote:
> I am missing something in creating an instance in Enterprise.  I have the 
> site created, the directory structure is there.  It is an internal site on 
> the Coldfusion box. The server is XP with Windows IIS 6.  In IIS Manager, I 
> can see the site in the application pool and added a virtual site to map to 
> it.  
>
> Do I need to run JRUN Administrator and do something else as well?
>
> When I try to go to the site it says Unable to display the webpage 
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:338726
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


cfquery, cachedwithin and cfscript

2010-10-01 Thread rex

Does anyone know how to cache a query using cfquery but in cfscript?

This works, query is cached for a day:

SELECT GETDATE()



But this doesn't, it's always cached = false:

qry = new query();
qry.setDatasource("stuff");
qry.setSql("SELECT GETDATE()");
qry.setCachedWithin("1");
qry = qry.execute().getResult();
writedump(qry);


I know it's there, since doing  will dump the function.  For the cachedwithin 
value, I've tried createTimeSpan(1,0,0,0) but it doesn't work too.

I'm on CF9.0.1, if it matters.

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:337760
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: WHERE Left(str,5) = 'string' VS WHERE str LIKE 'string%'

2010-09-14 Thread rex

Over 100,000 queries this is what I got (in ms):
LIKELEFT
MyISAM 16,215.60   16,069.00
InnoDB 16,168.60   15,987.80
MSSQL Server   28,268.60   26,775.20
Won's Test   1,184.401,168.80
INDEXED MyISAM 16,256.20   16,303.20
INDEXED InnoDB 16,112.40   16,119.00
INDEXED MSSQL Server   24,509.40   25,337.40
INDEXED Won's Test   1,156.601,159.00


LEFT() wins for unindexed columns, LIKE wins for indexed columns.

The answer is "it depends", but eventually the answer becomes "it won't 
matter".  These days, the sql engine/optimizer is smart enough to decide 
how to approach the problem.

"It depends" on certain things:
how wide your column is
if the column is indexed
how wide the search string is
how many records returned
how many records being searched
datatype of the column
etc. etc.

Then eventually "it won't matter", since the results would only be 
nanoseconds apart (if you are comparing exactly the same columns).  This 
is over 100K queries and they're only ms apart.  I'd love to see other 
people's test results though!

Won Lee wrote:
> I ran a quick test
>
> CREATE TABLE HoF (
>  ID INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
>  LastName VARCHAR(100)
>) ENGINE = InnoDB;
>
>
>   


~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:337034
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF8+: Short Hand notation for calling a function within a component.

2010-09-14 Thread rex

Yea, I dont know if you saw my other post.  In your case, my answer is 
totally wrong.  A lot of us thought that your function was expecting two 
arguments: name and likes, but it turns out you were taking in one 
argument of type struct.  Before CF9, you can't call a function and pass 
an implicit struct.

Michael Grant wrote:
> There's nothing wrong with it. However I wasn't asking how to write a
> function. My post was asking if I was wrong about passing in args as a short
> handed struct. And apparently I'm wrong with regards to cf<9.
>
> On Tue, Sep 14, 2010 at 8:06 PM, rex  wrote:
>
>   
>> why use a struct?  what's wrong with
>>
>>myFunction(name="mike", likes="beer,soccer,women");
>>
>> if you want it shorter, then don't name the arguments, just do name and
>> likes in order:
>>
>>myFunction("mike", "beer,soccer,women");
>>
>>
>> Michael Grant wrote:
>> 
>>> Calling a function from within the same component. For some reason I was
>>> sure that you could do this this way:
>>>
>>> 
>>>
>>> myFunction( {name="mike", likes="beer,soccer,women"} );
>>>
>>> 
>>>
>>> Am I crazy?
>>>
>>>
>>>
>>>   
>> 
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:337033
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF8+: Short Hand notation for calling a function within a component.

2010-09-14 Thread rex

oh, wow, I got confused there...

This guy wasn't doing







So here, there's no need for argumentCollection, he can just do 
myFunction("mike", "beer,soccer,women")

Turns out, he was doing this:






so this is a problem.  In CF8.0.1, you cannot pass in an implicit struct 
when calling a function.  In CF8.0.0 you cannot even do an implicit 
struct inside an implicit struct:



There's the rub!

Andy Matthews wrote:
> Right. Not allowed in CF8, but it is allowed in CF9.
>
>
>
>
> andy 
>
> -Original Message-
> From: Leigh [mailto:cfsearch...@yahoo.com] 
> Sent: Tuesday, September 14, 2010 3:07 PM
> To: cf-talk
> Subject: Re: CF8+: Short Hand notation for calling a function within a
> component.
>
>
> I do not remember that being allowed in CF8. But you could assign the
> structure to a variable. Then use argumentCollection
>
> 
> args = {name="mike", likes="beer,soccer,women"}; myFunction(
> argumentCollection=args ); 
>
>
>
>   
>
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:337027
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF8+: Short Hand notation for calling a function within a component.

2010-09-14 Thread rex

Maybe I'm confused, sorry, but isn't this the same as 
myFunction(name="mike", likes="beer,soccer,women")?

Leigh wrote:
> I do not remember that being allowed in CF8. But you could assign the 
> structure to a variable. Then use argumentCollection
>
> 
> args = {name="mike", likes="beer,soccer,women"};
> myFunction( argumentCollection=args );
> 
>
>
>
>   

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:337026
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CF8+: Short Hand notation for calling a function within a component.

2010-09-14 Thread rex

why use a struct?  what's wrong with

myFunction(name="mike", likes="beer,soccer,women");

if you want it shorter, then don't name the arguments, just do name and 
likes in order:

myFunction("mike", "beer,soccer,women");


Michael Grant wrote:
> Calling a function from within the same component. For some reason I was
> sure that you could do this this way:
>
> 
>
> myFunction( {name="mike", likes="beer,soccer,women"} );
>
> 
>
> Am I crazy?
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:337024
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Finding if a key exists in a struct based on a variable name

2010-09-07 Thread rex

A lot of people get DE() wrong.

IIF does not short-circuit 
(http://en.wikipedia.org/wiki/Short-circuit_evaluation), meaning that 
your DE() gets evaluated even if the condition is FALSE.  So, this will 
break:
#iif(false, notFalse, false)#
since notFalse does not exist.  Same here:
#iif(true, true, fols)#
since fols does not exist.  And finally your code:
#iif(false, DE(x.classAssign["#y#head"]), DE(''))#
breaks since x.classAssign["NAMEhead"] does not exist.

DE evaluates a STRING parameter and finds double-quotes.  If you pass in 
a variable, it looks for the value of that variable.  Since you are 
passing x.classAssign["#y#head"], it looks for x.classAssign["NAMEhead"] 
and breaks.

This will work: evaluate(DE("x.classAssign['#y#head']"))  - notice the 
single-quotes surrounding #y#head!  This is because we don't want DE to 
escape this, so we don't want to wrap it around double-quotes!

Here is the code (I used "no value" instead of "", but it's still the 
same code that you use):




#iif(StructKeyExists(x.classAssign,"#y#head"), 
evaluate(DE("x.classAssign['#y#head']")), DE("no value"))#

#iif(StructKeyExists(x.classAssign,"#y#head"), 
evaluate(DE("x.classAssign['#y#head']")), DE("no value"))#


See how these two differ: 
#DE("x.classAssign['#y#head']")#
#DE('x.classAssign["#y#head"]')#


Michael Grant wrote:
> HA! So I'm not the only one!
> So I thought DE meant "Delay Evaluation" as in "Don't evaluate what's in
> these little brackets this until you've satisfied the IIF condition."
>   
>

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336885
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Incorrect Perfmon Values in CF9

2010-08-26 Thread rex

Caveat: this option is unavailable on a J2EE install, as it is only 
available on a standard installation

WebMastesr Smarte wrote:
> CF Admin > DEBUGGING & LOGGING > Debug Output Settings > Enable Performance 
> Monitoring
>   
>

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336603
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: date format fo mySql

2010-08-20 Thread rex

wierd, my first reply didn't go through...

Rick is right.  Use cfqueryparam and your problems will go away:

INSERT INTO xTable(xDate) VALUES ();

That's for a DATE column.  If you are doing a DATETIME column, use 
cf_sql_timestamp instead.

You can also use Michael Grant's method by converting it first to an 
ODBCDATE/DATETIME formatted object

Rick Root wrote:
> #1 - are you using  to do the insert?
> #2 - To help us fix the error, it would be helpful to see the full
> error text as well as the code that is generating it.
>   


~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336449
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: date format fo mySql

2010-08-20 Thread rex

Rick is right.  Use cfqueryparam and your problems will go away:

INSERT INTO xTable(xDate) VALUES ();

That's for a DATE column.  If you are doing a DATETIME column, use 
cf_sql_timestamp instead.

Rick Root wrote:
> On Fri, Aug 20, 2010 at 12:26 PM, Rob Voyle  wrote:
>   
>> Hi Folks
>>
>> I have a coldfusion variable
>>expireDate=Dec. 10, 2010
>>
>> That I want to insert as a date into a mySql database
>> The table cell is set up as a date but I can't find the right cf date format 
>> to get
>> the insert to work. I keep getting a syntax error.
>> 
>
> #1 - are you using  to do the insert?
> #2 - To help us fix the error, it would be helpful to see the full
> error text as well as the code that is generating it.
>
>
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336448
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Millions of Coldfusion sites need to apply patches

2010-08-11 Thread rex

By golly it worked!  Is the CFIDE/scripts directory the only one needed 
to be remapped?

Mark Mandel wrote:
> Just expose the scripts, you don't have to expose the entire admin.
>
> This could be done by simply copying them, or if you are on Apache, use
> aliases, or on Linux, symbolic links, IIS Virtual directories (I think, I
> don't really use IIS)...
>
> Lots of options.
>
> Mark
>
> On Thu, Aug 12, 2010 at 8:52 AM, rex  wrote:
>
>   
>> If we restrict access to CFIDE, won't the tags that make use of
>> resources in this directory break?
>>
>> For example, the CF ajax features reference the file
>> cfide/scripts/ajax/package/cfajax.js
>>
>> If we block CFIDE, these would break.  What would be the workaround?
>>
>> Procheckup news wrote:
>> 
>>> Regrettably Adobe has seen fit to release only patches for version 8 and
>>>   
>> version 9.
>> 
>>> The easiest solution is to restrict access to /CFIDE/, which
>>>   
>> unfortunately only a slight majority of Coldfusion sites have done.
>> 
>>>   
>> 
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336206
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Millions of Coldfusion sites need to apply patches

2010-08-11 Thread rex

If we restrict access to CFIDE, won't the tags that make use of 
resources in this directory break?

For example, the CF ajax features reference the file 
cfide/scripts/ajax/package/cfajax.js

If we block CFIDE, these would break.  What would be the workaround?

Procheckup news wrote:
> Regrettably Adobe has seen fit to release only patches for version 8 and 
> version 9.
>
> The easiest solution is to restrict access to /CFIDE/, which unfortunately 
> only a slight majority of Coldfusion sites have done. 
>
>   

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336204
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: How to tell what hot fixes are applied.

2010-08-06 Thread rex

In CFAdmin (CF9), if you click on SERVER SETTING > SETTINGS SUMMARY, 
there's a line called UPDATE LEVEL under SYSTEM INFORMATION > SERVER 
DETAILS.  This is not in CF8 for some reason.

In both CF9/CF8 CFAdmin, you can click on the "i" icon at the upper 
right, next to the LOGOUT link, and it should display the UPDATE LEVEL 
as well.

CAVEAT: I know I installed some other hotfixes on my CF8 server, but it 
only displays chf8010004 (cumulative hotfix 4).  I know I installed the 
XSS hotfix 
(http://www.adobe.com/support/security/bulletins/apsb09-12.html 
) and 
the BlazeDS hotfixes 
(http://www.adobe.com/support/security/bulletins/apsb10-05.html) for 
CF8, but it does not display it anywhere.

Ian Skinner wrote:
>   A understand the one looks at the information page, but what does one 
> actually look for?
>
> We just resolved several issues with one of our servers that interrupted 
> the patching process a few weeks back.  Now I would like to confirm what 
> patches have been applied to what servers before resuming work.
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:336075
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: www.cbo.gov down. CF to blame?

2010-07-28 Thread rex

Any technology can be setup so that it doesn't scale well, or not scale 
at all.  This can be on PHP, dotNet, Rails, IIS, Apache, Nginx... I 
could go on...

One server can only handle so much.  Getting linked on drudge would send 
so many people to a site, and depending on how that site is setup, it 
may be sending all those people to one server!

Anyone hear of getting "slashdotted?"  Same difference:  
http://en.wikipedia.org/wiki/Slashdot_effect

It has the same effect as a "distrubuted denial of service" attack. 

This happens to the best of the web.  It happened to AT&T when the 
iPhone 4 was available for download 
(http://gizmodo.com/5563909/apple-iphone-4-pre+ordering-is-a-total-disaster).  


Same thing brought down Amazon during black friday and some other 
instances 
(http://www.betanews.com/article/Amazon-goes-down-for-the-count-twice/1213030157)

Or how about killing the datacenter itself: 
http://www.theregister.co.uk/2007/11/13/rackspace_texas_truck/

Yeah, sure, blame all these on ColdFusion... btw, I'm being sarcastic :-)

Look at how many servers are needed to run high-traffic servers: 
http://www.paragon-cs.com/wordpress/?p=144

Do you have 10,000 servers for your website?  Facebook does.  They need 
them to serve 500 million users.

How about 5 CF servers that serve 48,000 concurrent users?  Check that 
out here: 
http://www.cfwhisperer.com/post.cfm/coldfusion-9-and-48-000-concurrent-users

Now, that one we can blame on ColdFusion!

Greg Luce wrote:
> down. Drudge linked to it I guess and crashed the site and they are blaming
> CF. The error is HTTP Error 503. The service is unavailable. Isn't this an
>
>   

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:335814
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Adding 2 images with cfpdf

2010-07-21 Thread rex

Maybe you can combine the two images into one, then add the combined 
image into the pdf, since it's now a single image.

If you need it to be dynamically combined, you can use  or 
ImagePaste() to combine the two images

Mallory Woods wrote:
> Hello all,
>
> I have run into a situation in which I need to add two different images to a
> PDF. Adding the first image as a watermark works without issue.
> When I try to add the 2nd image, it removes the first watermark. I
> understand why this is happening but I wanted to see if anyone else came up
> with a created solution to add two separate images.
>
> Thanks,
>
> Mal
>
>   

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:335617
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: CGI.SERVER_NAME

2010-05-28 Thread rex

I just did some tests, and CGI.SERVER_NAME displays whatever URL was 
used to access the page.

So if the IP address is 1.1.1.1, and these three hosts point to 1.1.1.1: 
x.com, b.com, xb.org, and they all point to the same webpage with this code:



it'll output the following:

url: http://1.1.1.1
outputs: 1.1.1.1

url: x.com
outputs: x.com

url: b.com
outputs: b.com

url: xb.com
outputs: xb.com

Since you are using curl and you are specifying the IP in the URL, 
CGI.SERVER_NAME will be 1.1.1.1.  Since this is a private IP address, 
under certain circumstances, this should never leak.

For example, it could leak if you have a device (proxy server or load 
balancer) between the internet and the server, and all requests are 
being proxied from this device, and the device talks to your server via 
IP, and not via a hostname, then the internet would see the IP address 
as CGI.SERVER_NAME

Chad Gray wrote:
> While going through PCI compliance it appears that CGI.SERVER_NAME can leak 
> the internal private IP address.
>
> Does CGI.SERVER_NAME default to the internal IP setup in IIS?
>
> I have a re-direct in Application.cfm that if the user is on HTTPS to 
> cflocation them to http://#CGI.SERVER_NAME#/ and this leaks the private IP 
> 10.1.0.0 when using CURL
>
> curl -0 -k --head -v -H "Host: "https://1.1.1.1
>
>
>   

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334100
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Search for any that is referencing any UNC path.

2010-05-04 Thread rex

Try a file search in Eclipse/CF Builder and try this regex:



Ian Skinner wrote:
> I have a pretty tall challenge here.  Search our entire code base for 
> any cfml file that uses a  tag to read or write to a network 
> resource with an UNC path.  My tools available - whatever comes on an 
> ordinary Windows XP workstation.
>
> Any ideas?  I used the Windows Search for  and got a largish 
> list, but I know many of those do not deal with UNC paths.  I could not 
> find any way to search only the search results.  I attempted to try a 
> search for  and that it probably would not finish before the state furloughs ended.  
> But, instead, it just crashed my Windows Explorer after several minutes.
>
> 

~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:36
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: ssis 2005 question

2010-04-26 Thread rex

+1

This is indeed the way to go.

Another option, since you manage both servers: link one server to 
another and just do an SELECT INTO:

SELECT * INTO newtable FROM 2KServer.db_name.dbo.table_name

- Rex

Mike Chabot wrote:
> I would advise avoiding the migration wizard in SSIS. In my experience
> it doesn't work very well. It is easier and faster to use the
> backup/restore or detach/attach methods when it comes to upgrading SQL
> Server.
>
> -Mike Chabot
>   
>

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:333145
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: listgetat problem...

2010-03-15 Thread rex

this better illustrates what I meant


#listLen(lstText, ",")#

It will output 3

rex wrote:
> listGetAt() sees the "," inside the double-quotes as a list item.  So it 
> sees this piece of text as two items in the text lstText: 
>
> 
> #listLen(lstText, ",")#
>
> Instead of doing this via CF, try leveraging MySQL's text importer.  It 
> will be much faster. 
>
> MySQL has to have access to the file.  Here is the command:
>
> LOAD DATA INFILE 'data.txt' INTO TABLE tbl_name
> FIELDS TERMINATED BY ','
> ENCLOSED BY '"'
> LINES TERMINATED BY '\n';
>
> MySQL will load the file data.txt into the table tbl_name, so the table 
> needs to exist.  The delimiter is specified by FIELDS TERMINATED BY.  
> ENCLOSED BY will tell it that all imported data are surrounded by 
> double-quotes.  LINES TERMINATED BY will specify the row delimiter.  On 
> windows, change this to '\r\n' (carriage return + line feed)
>
> Les Irvin wrote:
>   
>> Hi all -
>>
>> I'm trying to (unsuccessfully) import a comma delimited text file
>> (from an MLS service) into a MySQL db and looping over the file using
>> listgetat in this manner:
>>
>> ...
>> '#listgetAt('#index#',4, ',')#',
>> '#listgetAt('#index#',5, ',')#',
>> '#listgetAt('#index#',6, ',')#'
>> ...
>>
>> I'm suspecting that the format of the text file is breaking my code.
>> Here's a sample of the text file.
>>
>> "RES","A","AUN",776082,877,"","ST","RACINE","HOFFMAN
>> TOWN",80011,3,2,"RES","1051","","","KELLER WILLIAMS REALTY
>> LLC","CHARMING RANCH STYLE HOME, 3 BEDROOMS, 2 FULL BATHS, CONCRETE
>> EXTENDED DRIVEWAY (ISSUES), NO FHA !!",5,"",,"","AURO",1681,
>>
>> Note that text items have quotes around them and number items don't.
>> Also, text items can and do include commas within.  Am I improperly
>> using the listgetat function?  If so, how can I rewrite it to get
>> around these issues?
>>
>> Many thanks in advance,
>> Les
>>
>>
>> 
>
> 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:331771
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: listgetat problem...

2010-03-15 Thread rex

listGetAt() sees the "," inside the double-quotes as a list item.  So it 
sees this piece of text as two items in the text lstText: 


#listLen(lstText, ",")#

Instead of doing this via CF, try leveraging MySQL's text importer.  It 
will be much faster. 

MySQL has to have access to the file.  Here is the command:

LOAD DATA INFILE 'data.txt' INTO TABLE tbl_name
FIELDS TERMINATED BY ','
ENCLOSED BY '"'
LINES TERMINATED BY '\n';

MySQL will load the file data.txt into the table tbl_name, so the table 
needs to exist.  The delimiter is specified by FIELDS TERMINATED BY.  
ENCLOSED BY will tell it that all imported data are surrounded by 
double-quotes.  LINES TERMINATED BY will specify the row delimiter.  On 
windows, change this to '\r\n' (carriage return + line feed)

Les Irvin wrote:
> Hi all -
>
> I'm trying to (unsuccessfully) import a comma delimited text file
> (from an MLS service) into a MySQL db and looping over the file using
> listgetat in this manner:
>
> ...
> '#listgetAt('#index#',4, ',')#',
> '#listgetAt('#index#',5, ',')#',
> '#listgetAt('#index#',6, ',')#'
> ...
>
> I'm suspecting that the format of the text file is breaking my code.
> Here's a sample of the text file.
>
> "RES","A","AUN",776082,877,"","ST","RACINE","HOFFMAN
> TOWN",80011,3,2,"RES","1051","","","KELLER WILLIAMS REALTY
> LLC","CHARMING RANCH STYLE HOME, 3 BEDROOMS, 2 FULL BATHS, CONCRETE
> EXTENDED DRIVEWAY (ISSUES), NO FHA !!",5,"",,"","AURO",1681,
>
> Note that text items have quotes around them and number items don't.
> Also, text items can and do include commas within.  Am I improperly
> using the listgetat function?  If so, how can I rewrite it to get
> around these issues?
>
> Many thanks in advance,
> Les
>
> 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:331770
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: cfmail with gmail - second question

2010-01-29 Thread rex

According to 
http://mail.google.com/support/bin/answer.py?hl=en&answer=13287 
 gmail 
requires either SSL or TLS to send email from a client

I tried your code, but added the following and it worked:
port="465"
useSSL="true"

I haven't tried it, but if you want to use TLS instead of  SSL, you can do
port="587"
useTLS="true"


TechInfo wrote:
> Did you try putting ALL the attributes into the attributeCollection?  
> Even the "port" and "useSSL" ??  I just read that it is an "all or 
> nothing" collection.
>
> Jevo
>
> Matthew Smith wrote:
>   
>> I posted earlier about using cfmail with google hosted mail.  I was told it 
>> would require cf8.  We ended up upgrading the account to cf8, but I still 
>> can't get it to work.  Here is what I have.  The page runs without error, I 
>> just don't ever receive the test mail:
>>
>> > server="smtp.gmail.com",
>> username="webs...@website.com",
>> password="password",
>> from="webs...@website.com",
>> to="rece...@gmail.com",
>> subject="Eat my shorts"
>> }
>> />
>>
>> > attributeCollection="#mailAttributes#"
>>   
>> 
>>> port 465, SSL enabled
>>> 
>>>   
>> > attributeCollection="#mailAttributes#"
>>   
>> 
>>> port 587, TLS enabled
>>> 
>>>   
>> > attributeCollection="#mailAttributes#"
>>   
>> 
>>> port 465, SSL and TLS enabled
>>> 
>>>   
>>
>> 
>
> 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:330253
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: original request before mod_rewrite alters it

2009-11-16 Thread rex

Hi James,

Thanks, that was it!  Doing a CFDUMP does not display the rewrite CGI 
variables, but they're there.  Thanks!

James Holmes wrote:
> Try the CGI.REDIRECT_URL variable.
>
> mxAjax / CFAjax docs and other useful articles:
> http://www.bifrost.com.au/blog/
>
>
>
> 2009/11/17 rex :
>   
>> How do I find the original request url before mod_rewrite kicks in?
>>
>> With ISAPI_Rewrite, it adds to the request "X-REWRITE-URL" with the
>> original request url.
>>
>> Is there an equivalent with Apache MOD_Rewrite?
>> 
>
> 

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328455
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


original request before mod_rewrite alters it

2009-11-16 Thread rex

How do I find the original request url before mod_rewrite kicks in?

With ISAPI_Rewrite, it adds to the request "X-REWRITE-URL" with the 
original request url.

Is there an equivalent with Apache MOD_Rewrite?

~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328440
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


(ot) people search

2009-05-16 Thread rex

Sorry for the off-topic post.

Someone mentioned on their blog/fullasagoog.com a "people-finder" 
website that's pretty amazing.

Can anyone recall that website, blog entry or blogger?

Again, apologies for the OT post.



~|
Want to reach the ColdFusion community with something they want? Let them know 
on the House of Fusion mailing lists
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:322594
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Backup MX

2009-05-01 Thread rex

Great, thanks!

Dave Watts wrote:
>> What about for MS Exchange users?  I know that they wouldn't like to
>> move away from Exchange's calendar and AD integration.  What would you
>> suggest?
>> 
>
> Well, I think the calendaring functionality of Google Apps is as good
> as that of Exchange. And it appears as an Exchange server if you're
> using an ActiveSync client on your Windows Mobile phone. AD
> integration can be performed using the SSO functionality in Google
> Apps Premier Edition, if you're using the web interface as opposed to
> Outlook IMAP.
>
> We just migrated from Exchange to Google Apps Premier, and I've been
> exceptionally happy with the result. We're not doing AD integration,
> because we're small enough that we can get away without doing it.
>
> Dave Watts, CTO, Fig Leaf Software
> http://www.figleaf.com/
>
> Fig Leaf Software provides the highest caliber vendor-authorized
> instruction at our training centers in Washington DC, Atlanta,
> Chicago, Baltimore, Northern Virginia, or on-site at your location.
> Visit http://training.figleaf.com/ for more informatio
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:322127
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Backup MX

2009-05-01 Thread rex

Thanks Dave.  I currently use that for my family's domain, since the 
standard edition is free.

What about for MS Exchange users?  I know that they wouldn't like to 
move away from Exchange's calendar and AD integration.  What would you 
suggest?


Dave Watts wrote:
>> Does anyone use a Mailbagging / Backup MX service?  I was looking at
>> dyndns.org, but I wanted to see if anyone on the list would recommend a
>> provider.
>>
>> I have a combined mail/cf/db server, and I just want to make sure that
>> when it goes down, that I won't lose any of my emails.  Website
>> visitors, they can wait, but not e-mail. ;-)
>>
>> Also, if they also do spam and virus filtering, but not really
>> required.  Thanks!
>> 
>
> Have you considered ditching your mail server altogether for a hosted
> service like Google Apps for your Domain? I'm very happy with that,
> myself. The Premier Edition provides Postini spam and virus filtering
> among other things. I ditched my mail server and haven't looked back
> since.
>
> Dave Watts, CTO, Fig Leaf Software
> http://www.figleaf.com/
>
> Fig Leaf Software provides the highest caliber vendor-authorized
> instruction at our training centers in Washington DC, Atlanta,
> Chicago, Baltimore, Northern Virginia, or on-site at your location.
> Visit http://training.figleaf.com/ for more informati
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:322125
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Backup MX

2009-05-01 Thread rex

Hello,

Does anyone use a Mailbagging / Backup MX service?  I was looking at 
dyndns.org, but I wanted to see if anyone on the list would recommend a 
provider.

I have a combined mail/cf/db server, and I just want to make sure that 
when it goes down, that I won't lose any of my emails.  Website 
visitors, they can wait, but not e-mail. ;-)

Also, if they also do spam and virus filtering, but not really 
required.  Thanks!

- Rex

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:322122
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: How long to ftp 100mb

2009-04-23 Thread rex

That is a very bad transfer speed.  I have 400kbits/sec upload speed on 
my DSL so a 100MB upload would take me 30 mins.

Have you tried what Wil suggested and just try a manual FTP transfer?  
Try it and see how fast it goes.  Maybe the external server is just slow.

Wil Genovese wrote:
> First thing I would try is to do a traceroute from your server to the
> external server to see if there is any issues.  Then I would try to ftp
> manually from the server to the external server.
>
> See if active or passive mode works better.
> Use cfzip to zip the file if you can.
>
>
> Wil
>
>
> On Thu, Apr 23, 2009 at 4:33 PM, Ian Skinner  wrote:
>
>   
>> I have a process that starts with a ColdFusion interface and ends with
>> an Oracle stored procedure FTPing a file from the database server to an
>> external FTP server.
>>
>> A test run today has spend 3.5hours and counting to ftp 100MB of text
>> data, that seems a bit slow to me is it?
>>
>> If it is, how would one start sniffing around to find the bottle neck?
>>
>>
>>
>>
>>
>>
>> 
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:321923
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Query - can't understand the error

2009-04-23 Thread rex

I forgot how access works, but SQL Server doesn't usually like those 
double quotes.

Also, see if maybe CF is escaping any of those quotes in those CF variables.

I'd see what the CFQUERY is generating first, then run it in Access and 
see how it fares there.

Fawzi Amadu wrote:
> Hello,
> I am in a quandary with my query, I have looked at it many times and cannot 
> find the error. I am getting a "too few parameters" error on the line with 
> variable filename8,   any insight into how to solve this is welcome. TIA
>
> Code:
>
> 
>Insert into Consumer_ProductExtraImgs(Cnsmr_ProductID, 
>  expandedImgID, 
>ExpandedImg1, 
>ExpandedImg2, 
>ExpandedImg3, 
>ExpandedImg4, 
>ExpandedImg5,
>ExpandedImg6, 
>  ExpandedImg7,
>   
>  ExpandedImg8,
>   
>  DescriptionforExpandedImg1,
>   
>  DescriptionforExpandedImg2,
>   
>  DescriptionforExpandedImg3,
>   
>  DescriptionforExpandedImg4,
>   
>  DescriptionforExpandedImg5,
>   
>  DescriptionforExpandedImg6,
>   
>  DescriptionforExpandedImg7,
>
> DescriptionforExpandedImg8)
>   
> Values('#(Session.ExtraProductImgName)#',
>  
> '#(expandedImgID)#',
>  
> '#(filename1)#',
>  
> '#(filename2)#',
>  
> '#(filename3)#',
>  
> '#(filename4)#',
>  
> '#(filename5)#',
>  
> '#(filename6)#',
>  
> '#(filename7)#',
>  
> '#(filename8)#',
> "",
> "",
> "",
> "",
> "",
> "",
> "",
> "")
> 
>
>
> And the error is:
>
> Error Executing Database Query.
>
> [Macromedia][SequeLink JDBC Driver][ODBC Socket][Microsoft][ODBC Microsoft 
> Access Driver] Too few parameters. Expected 1.
>  
> The error occurred in 
> C:\ColdFusion8\wwwroot\e-danta\uploadExtraConsumerProductImages.cfm: line 112
>
> 110 : '#(filename6)#',
> 111 : '#(filename7)#',
> 112 : '#(filename8)#',
> 113 : "",
> 114 : "",
>
>
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:321921
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: FireFox & getElementById issue?

2009-02-19 Thread rex

MemberName should have ID and NAME

If it works in IE, that means that MemberName only has NAME since IE 
resolves the getElementById function to both the ID and NAME of the object

in this code example, both selects will work in IE but only the second 
one will work in FF


xx
yy
zz



xx
yy
zz



function alertList(){
var list = document.getElementById("MemberName");
alert(list.options.length);
}
function alertList2(){
var list = document.getElementById("MemberName2");
alert(list.options.length);
}


Austin Band wrote:
> Hello, I need a little help. I have javascript that works with IE but not 
> FireFox. 
> 
> The code:
> 
> 
> function addItemsToParent(){
> var MemberList= "";
> var list = document.getElementById("MemberName").value;
> for(var i=0; i   if(list.options[i].selected){
>   MemberList = MemberList + ","+list.options[i].value;
>   }
>   opener.document.MemberName.value = MemberList;
>   self.close();
>   }
> 
> 
> The error returned in Error Console is that the list is null. This works 
> correctly in IE. The goal is to select a name and it displays in the textbox
> 
> 
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319516
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: struct/query strange behaviour

2008-11-11 Thread rex
Way to go Railo!

Well, even though it's unlikely that a valid SQL query would contain a
struct for a row (can it?), inserting a struct into a query variable is
allowed.

CF looks at the first record of a query variable whenever you reference
a column from it outside of a query-looping structure like with  or 

So, in this case, when you reference myQuery.Advanced[2] you are
actually looking at the value of the key "2", from the "Advanced" column
of the FIRST row of myQuery, which has 3 keys: CITY, FIRSTNAME,
LASTNAME, which is VALID, but NOT EXPECTED.

Railo looks at a query variable as a structure anyway, so when you
reference myQuery.Advanced[2], it finds the 2nd row of the query, since
it's just a regular structure, which is AS EXPECTED.

That is why this will fail in CF, but work in Railo:



The discussion should be that Adobe CF, or CFML (the language) should be
smart enough to know that when I reference query["column"][2], that I'm
trying to get to the 2nd record's column (which is more intuitive), and
not the value of the "2" key of the 1st record's column.

- Rex

Gert Franz wrote:
> Just a side note...
> 
> Railo returns StructCount = 2 and dumps a struct with two keys 
> containing 3 keys. I guess as expected.
> 
> Greetings from Switzerland
> Gert Franz
> Railo Technologies GmbH
> [EMAIL PROTECTED]
> www.railo.ch
> 
> Join our Mailing List
> german:http://de.groups.yahoo.com/group/railo/
> english:   http://groups.yahoo.com/group/railo_talk/
> linked in: http://www.linkedin.com/e/gis/71368/0CF7D323BBC1
> 
> 
> 
> to schrieb:
>> hi all,
>>
>>
>> i'm wondering if this has also happened to you (see code below)
>>
>> myQuery.Advanced[2] in CF7 results in a struct with "Totti" & "Del Piero",
>> but in CF8 gets "Lemont"
>>
>> what funny is that structcount result is 3 (!?!?)


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315126
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Access individual instances in a cluster without JWS?

2008-11-09 Thread rex
By JWS, do you mean JRUN Web Server?  How do you disable JRUN?



WebSite CFTalk wrote:
> Hello,
> 
> I've been struggling with clustering for a while now..
> 
> 2 physical servers with 2 JRun instances on each on W2003/iis6.0. (CFMX 8.01 
> Ent.)
> 
> Since 6.1 I've had no success with session replication across the cluster.
> 
> I finally found a solution for that;
> Session replication was failing until I disabled JWS (and that took quite 
> some time to find out.)
> 
> So now the cluster is running fine, but since JWS is disabled I cannot access 
> the admin instances on the cluster.
> (And not having access to the server monitor is not good..)
> 
> I tried to add the admin roots to IIS but that didn't work since the 
> instances then got clustered also.
> Then I tried to use Apache as a second web server tied to the admin root, but 
> I cannot find a way to connect that via the JRun connector.
> 
> So,
> Has anyone else experienced this?
> Have you got a solution on how to access the admin instances without JWS and 
> "outside" of the cluster?
> 
> Maybe there is a setting in JWS I've missed?
> 
> Thanks,
> Helge
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:315008
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Streamlining an insert

2008-10-16 Thread rex
Use two CFQUERYs:


select name from [user]




insert into otheruser (name) values ('#firstDSN.name#')



this insert (secondDSN) is essentially the same, but should be faster than:



insert into otheruser (name) values ('#firstDSN.name#')



Eric Roberts wrote:
> This is coming from a different datasource, so I need a way to use a cfquery
> resultset in the insert. I wish cfquery allowed one to specify a different
> datasource from within a query.
> 
> Eric
> 
> 
> /*-Original Message-
> /*From: Ryan Stille [mailto:[EMAIL PROTECTED]
> /*Sent: Wednesday, October 15, 2008 4:49 PM
> /*To: cf-talk
> /*Subject: Re: Streamlining an insert
> /*
> /*This is how you'd do it with MySQL:
> /*
> /*INSERT INTO tablename (x,y,z) SELECT x,y,z FROM othertable
> /*
> /*If you are using MSSQL, I'm sure its something similar.
> /*
> /*-Ryan
> /*
> /*Eric Roberts wrote:
> /*>
> /*>
> /*> I have been trying to come up with a more streamlined way to update the
> /*> contents of a table with data that is coming from a different database.
> /*Is
> /*> there a way to use in the values clause a reverence to a record from a
> /*cf
> /*> query instead of actually typing out all of the variables?  Something
> /*along
> /*> the lines of:
> /*>
> /*>
> /*>
> /*> Insert into table(x,y,z)
> /*>
> /*> Values(#queryname[currentrow]#)
> /*>
> /*>
> /*>
> /*> Or is there a way to use cfinsert or some other process where I could
> /*> essentially pass the query object so that I can insert the data without
> /*> having to loop and do each insert individually?
> /*>
> /*>
> /*>
> /*> Thanks!
> /*>
> /*>
> /*>
> /*> Eric
> /*>
> /*>
> /*>
> /*>
> /*>
> /*>
> /*>
> /*>
> /*>
> /*>
> /*>
> /*>
> /*
> /*
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313998
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Image display issue

2008-10-16 Thread rex
Don't use HTMLCodeFormat, it will escape your < and >

Can you output just one row, and make sure that it does output "bla ksk
kak alkd sk skd  sjd ksd fksdf" and that it
is not escaped in the database.

You don't need HTMLCodeFormat to view it, just view the source.  Make
sure that it outputs what it needs to output and that the whole thing is
not commented out, or other things to make it not display.

Try this code:



#myData#


bla ksk kak alkd sk skd  sjd ksd fksdf


This assumes that the first record for the getData query is "bla ksk kak
alkd sk skd  sjd ksd fksdf"

The code above should essentially display the same thing twice (with
whitespace):

 
bla ksk kak alkd sk skd  sjd ksd fksdf
bla ksk kak alkd sk skd  sjd ksd fksdf


View the source!  It's impossible that the browser will display one and
not the other because it does not know that one is being rendered by a
CFQUERY from a database!

Also, properly terminate your img tag and quote your attribute values:


Don L wrote:
> CF8, 
> outside query out:   -- displayed
> 
> output var value of image: #imgVar# -- displayed
> 
> db column named myData of varchar|nvarchar (5000), one row's data stream reads
> "bla ksk kak alkd sk skd  sjd ksd fksdf"
> query the above table and column (resultsets could be numerous rows)
> 
> , #myData# -- the image is not rendered, why not?
> 
> 
> I even tried HTMLCodeFormat to see what's there, here's its output
> show: 
> 
> Hmm, what could prevent the image reference from within a text string being 
> rendered by browser?
> 
> Thanks.
> Looks like simple but I'm stumbled by it.  Thanks.
> 
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313997
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Won't evaluate?

2008-10-10 Thread rex
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Like Aaron and Peter said, SCOPE your variables like so:








#VARIABLES.Question#



#VARIABLES.Answer#




When you are referencing #Question# you are actually referencing
#FAQ.Question# and not #VARIABLES.Question#, so it wont work

Phillip M. Vector wrote:
> Here's the full code.
> 
> 
> 
> 
> 
> 
>   
>   
>   #Question#
>   
>   
>   
>   #Answer#
>   
>   
> 
> 
> So yeah. it's looping fine. Just doesn't show any usercount.
> 
> Aaron Rouse wrote:
>> Is it inside a loop over a query?  If so then scope your outputed variables
>> in those div elements.  
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313751
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: strange (lt) behaviour

2008-10-07 Thread rex
All numeric data types in CF are typed as Java Strings.  You must do a
JavaCast() to type BigDecimal and do comparisons on that.  Here is your
modified code:






















#isValidFloatRange(1.999,1,3)#
#isValidFloatRange(1,1,3)#
#isValidFloatRange(2,1,3)#
#isValidFloatRange(2.999,1,3)#
#isValidFloatRange(3.1,1,3)#

#isValidFloatRange(0.999,1,3)#

#isValidFloatRange(1.0,1,3)#


Make sure to VAR your functions, and I've set a validation against
switched max/min Ranges (or you can just switch them)

Richard White wrote:
> hi,
> 
> i have a function that is passed a float value, a min float range, and a max 
> float range and it compares whether the float is in the correct range and 
> passes back true or an error:
> 
> 
>   
>   
>   
> 
>
>  #maxRange#)">
>   
> 
>   
> 
> 
> 
> however, it all seems to work fine until i put in the following criteria:
> 
> #isValidFloatRange(1.,2.00,3.00)#
> 
> for some reason it returns true saying that value is between 2 and 3. but if 
> i take one of the 9's out of the value then it produces the required error 
> saying it is not inbetween the range
> 
> has anyone come across this before or see if there is something i am missing
> 
> thanks
> 
> richard
> 
> 
> 
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313588
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: i'll pay through paypal anyone who can debug my code

2008-10-02 Thread rex
Hello Phillip,

I'm interested in debugging your code.  Also, I'll need specifics about
your platform:

1. OS
2. CF engine and version
3. If there is any DB interaction, the SQL engine and version

Thanks!

Phillip Perry wrote:
> Hi,
> 
> I have been over this cookie code for over a week and I can't get it
> straight, even with the help of people who I feel (and know) are
> experts. So now I'm offering $50 to the first person who can show me
> where the problem is and come up with a workable solution. I'm not
> looking for someone to write , or rewrite my code. Just tell me whats
> wrong with mine and offer a solution. If you're interested please
> contact me at [EMAIL PROTECTED] for further details and the code
> as it currently stands.
> 
> Thanks,
> 
> Phil
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313411
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Coldfusion 8 on Linux Installation ( Linus ver. ie. Aspire One laptop )

2008-08-26 Thread rex
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

I have CF8 running on Debian 4 on a P3-800 MHz 512MB RAM, 12GB HDD

I have 256MB assigned to the JVM, and it works fine for a small app.
I'm sure you'll run into memory issues, though, if your app needs it.

Don wrote:
> Anyone else? thoughts or opinions?
> 
>> I looked at it and it seems to come with 512MB, now about a week ago I tried 
>> to Install ColdFusion on one of my old desktops and it would not start till 
>> i put 1.5GB of ram. The Jrun just gives memory errors so..., I know on Adobe 
>> it says Minimum of 512MB but I never was able to install. It was on a CentOS 
>> box.
>> laptop )
>>
>>
> 
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:311552
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Why wasn't this error caught by my onError function

2008-08-09 Thread rex
You should have onError() in place to handle runtime errors, and also 
make sure you have the site-wide error handler in CF Admin to handle 
compile time errors (like syntax errors). 

Also in CF Admin, don't forget to specify the missing template handler.

Setting these up would prevent unexpected displays of the regular 
exception screen.

Michael Brennan-White wrote:
> Okay that makes sense.  Thanks for the help.  
>
>   
>> Which is a syntax error and can't be caught by error handling.
>>
>> 
>> ...
>>
>>
>> 
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:310640
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: Single vs Cluster - Session Variables - session.cfid HELP

2008-07-30 Thread rex
Hello,

Check the ff on all your cluster members:
1. REPLICATE SESSIONS option enabled
2. J2EE Sessions enabled

Also, when initially setting up, you'd have to stop and start all instances.

Btw, are you clustering multiple instances on the same machine (vertical 
cluster) or across physical servers (horizontal cluster)?



[EMAIL PROTECTED] wrote:
> Why is it that I can get a I thought a session.cfid out of a single server 
> config, but not a cluster?
>
> >From the code below, I get an error on a cluster configuration.
>
> Element CFID is undefined in SESSION. 
>
>  
> The error occurred in D:\Inetpub\wwwroot\website\Application.cfm: line 9
>
> 7 : 
> 8 : 
> 9 : 
> 10 : 
> 11 : 
>
>
>
>
>  setclientcookies="yes">
> 
>
> 
> 
> 
> sessionID: #session.sessionID#
> cfid: #session.cfid#
> cftoken: #session.cftoken#
> 
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309974
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Directory contents to list/array?

2008-07-23 Thread rex
You can also do Java's File Class, which returns an array.  I haven't 
done speed tests, but it *should* be faster for big directories:

listDirectory = 
createObject("java","java.io.File").init("/var/absolute/directory/path").list();

Let us know if it's faster for you

Melissa Cope wrote:
>> The query you get from cfdirectory is an array (or rather, its columns 
>> are):
>>
>> > yourCFFileQuery["name"][randRange(1,yourCFFileQuery.recordCount)]>
>> 
>
> I can't believe I didn't thank of that! Thanks so much. 
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309537
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: XML Error = invalid character Unicode 0x19.

2008-07-04 Thread rex
Dominic Watson wrote:
> Apparently, the org.apache.commons.lang.StringEscapeUtils java class'
> escapeXml method escapes this (and other) characters properly. So
> something like:
>
>  'org.apache.commons.lang.StringEscapeUtils')>
> 
>
> When I first tested this out I found that the
> org.apache.commons.lang.StringEscapeUtils class could not be found so
> I had to install the org.apache.commons.lang package which can be
> found here:
>
> http://commons.apache.org/downloads/download_lang.cgi
>
> Note: I've not been able to test this with a string that produces the
> error you are having.
>
> HTH
>
> Dominic
>
>   
I remember using safetext 
(http://cflib.org/index.cfm?event=page.udfbyid&udfid=56) to remove the 
special chars like:

‘the quicj’

Dr – jhg


and other stuff. Please test and I hope it works

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308595
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: cfxml vs xmlnew() vs xmlnew(true) - (Solved)

2008-06-30 Thread rex
I should be referencing the root node in xmlRoot:


  myXML = xmlNew(true);
  myXML.xmlRoot = xmlElemNew(myXML, "breakfast_menu");
  myXML.xmlRoot["food"] = xmlElemNew(myXML, "food");
  myXML.xmlRoot["morefood"] = xmlElemNew(myXML, "morefood");
  myXML.xmlRoot["food"]["name"] = xmlElemNew(myXML, "name");



Thanks!

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308353
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


cfxml vs xmlnew() vs xmlnew(true)

2008-06-30 Thread rex
Hello everyone,

I have this code that should generate the same exact XML three ways, but 
I can't get the third way to work.

1. cfxml - this works exactly the way I want it.



   
   Belgian Waffles
   Our famous Belgian Waffles
   
   




2. xmlNew() - this works like cfxml, but quantity and quantity2 
attributes come out as uppercase














3. xmlNew(true) - I'm trying to get the quantity/quantity2 attributes to 
be case sensitive.  I cannot get this to work at all.  I cannot add the 
child node "name" under "food"


   myXML = xmlNew(true);
   myXML.xmlRoot = xmlElemNew(myXML, "breakfast_menu");
   myXML.xmlRoot["breakfast_menu"][1] = xmlElemNew(myXML, "food");
   myXML.xmlRoot["breakfast_menu"][1] = xmlElemNew(myXML, "morefood");
   myXML.["breakfast_menu"]["food"][1] = xmlElemNew(myXML, "name");
   //myXML.xmlRoot[1][1][1] = xmlElemNew(myXML, "name"); //does not work
   //myXML["breakfast_menu"]["food"][1] = xmlElemNew(myXML, "name"); 
//this does not work
   //myXML.xmlRoot["breakfast_menu"]["food"][1] = xmlElemNew(myXML, 
"name"); //this does not work
   //myXML.xmlRoot[1][1][1] = xmlElemNew(myXML, "name"); //this does not 
work



http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=XML_08.html 
says not to use dot notation when referencing case sensitive XML.  One 
of the examples in there, I cannot get to work:

MyDoc.["employee"]["name"][1]


which would translate to my code as:

myXML.["breakfast_menu"]["food"][1]

I get an error saying 'A CFML variable name cannot end with a "." 
character.'

Thanks for the help!



~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308346
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: submitting a form

2008-06-27 Thread rex
Claude Schneegans wrote:
>  >>It is possible to spoof anything in an HTTP request to your server.
>
> Of course, but not in this case.
>
>   
How do you know that the submission was from your page?  Do you check 
for the http referer on your action page?  Like Brad Wood and Dave 
Francis said, someone could have submitted the data from a similar form 
without the js checks (like a form copied locally and submitted to your 
action page).

Or like Sonny Savage mentioned, it could be something simple like js 
failure.  It's happened so often that the 0.001% of your user base has a 
wierd client that displayed the form anyways and jumped your validation 
and posted to your action page.  Or, your js that checks the two 
required date fields has a bug.

If you have a created-timestamp column on your registration table, you 
can map the date/time of the insertion against your web server logs to 
look at the form submission entry, and find out the user-agent and 
previous GET/POST attempts from the same IP.  Also look at the status 
pages.  CF will serve up 500 errors if there was a server exception, 
like a database error.  If someone did try spoofing your submission 
page, it would have taken him multiple tries to make a successful 
submission, and this would be logged by the web server.  The logs will 
also show you the referer (this is disabled by default on IIS).

Also, don't eliminate the possibility that the data was not inserted 
through the action page.  Make sure that the logs show that it was 
inserted by the action page.  If your action page inserts into the 
database, and also cfmails you, then you can at least confirm via the 
email you received that it was submitted through the website.  But if 
all your action page does is insert into the db and display a "success" 
screen to your user, then all you have to prove that it was through the 
website is the weblogs.  If you can't find the appropriate web 
submission in the logs, then you have a db problem.

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308274
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: cfloop using to much memory

2008-06-26 Thread rex
Sam Roach wrote:
> We are trying to create a CSV file with about 250,000 rows with about 40
> dynamic columns which we need to loop over so we can get the correct order.
>
> We see an issue coming from the nested loops on the large dataset and the
> server is running out of memory.   We took a step back on even doing a
> simple loop over over a large set of rows seems to have the same issues.
> Anyone have any ideas how to deal with this?
>
> If you run this code on watch the memory on the CF Server it will just keep
> climbing until garbage collection runs.
>
> 
>
> 
> 
>
>
> thanks,
> -- Sam
>
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:308176
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Best way to cause scheduled tasks to run consecutively?

2008-05-24 Thread rex
Since a CF Scheduled task is basically just a call to a webpage, just 
put a  in your code.

So, your scheduled task will be calling task1.cfm, and the last part of 
your code would be a 

If you are only doing queries, the best way to do it would be on the SQL 
side.  A stored procedure as a SQL job would be the way to go.  That 
way, you can wrap everything around a transaction and rollback when it 
breaks.  It'll be faster, plus if you use a CF Scheduled Task, you will 
be breaking out your queries and you cannot do CFTRANSACTIONs.

And, yes, even though you can still do regular transactions, bear in 
mind that if your CF errors out with open transactions you will run into 
locking issues.  Doing this on the database side is the best way to 
approach this.

Rick Faircloth wrote:
> Thanks, Mike and Mary Jo...
>
> Questions:
>
> I'm not able to think of how to code a task to "call"
> another... nothing's coming to mind.  How would I accomplish that?
>
> Also, the logic to insure a previous task completed... such as
> a variable that is set to "true" or something like that?
>
> And, Mary Jo, concerning rollback...would cftransaction be appropriate?
> The  processes aren't dependent upon one another, they are just long-running
> and rather processor intensive so I don't want any concurrent tasks running.
>
> If I were to put all tasks into one long file and put them into a single
> named thread, would that be a good approach?  Problems with that?
>
> Thanks for the suggestions!
>
> Rick
>   


~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:306022
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: OT - https requests stop working after Firewall and IP changes

2008-04-16 Thread rex
James Blaha wrote:
> Hi Dave,
>
> If you go on the CF server locally can you call a cfm page via HTTP and HTTPS?
>
> Where is the SSL cert sitting?
>
>   
If SSL still fails locally, check out the SSL Diagnostic Tool at 
http://www.microsoft.com/windowsserver2003/iis/diagnostictools/default.mspx

SSL is very picky especially if the cert wasn't issued on a requesting 
server (by that I mean the cert didnt follow the normal cycle of 
request-submit-download-install)

"Reissuing" it the way you did did not do anything.  I suggest that you 
backup/export the SSL cert and key and reimport it after the IP changes.

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303657
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: weird issue in browser with cf8 and long execution times

2008-04-14 Thread rex
Yes, Ravi is correct.  If CF is not connected to your webserver, the 
CFML will not run at all, and data will not be inserted.

Are you doing some kind of cfheader/cfcontent, or javascript relocate 
somewhere? 

I'm thinking if your code does something like this:
1. get the XML
2. parse through it
3. do your cfcontent, or serve up another page that results in the 
blank file
4. loop through your data and insert into DB

1 and 2 is why it takes a while to have that dialog box to save 
index.cfm come up.

3 is what makes that dialog box come up

4 keeps on going because the request has been made.  You've confirmed 
this in MySQL.  It's like a user going to "long_running_page.cfm", and 
then not waiting for the page to load and navigate to 
"any_other_page.cfm". "long_running_page.cfm" is still executing on the 
server, even though the user is totally unaware of it (most users anyway). 

If it was the web connector, then the cfm file would never execute, and 
just get served up like ordinary html, by either displaying the unparsed 
cfml, or asking the file to be saved.


[STS] Ravi Gehlot wrote:
> It is weird that it asks you to save the index.cfm file. The only time I had
> that problem was when IIS was not configured to open CFM files. Same had
> happened with Apache. But since you are saying that the process are running
> on the background with data being inserted into the database it makes me
> think that this is not a problem of adding CFM to IIS/Apache Index
> Directory.
>
> Ravi.
>
>
>
>
> On Sun, Apr 13, 2008 at 7:30 AM, Rick Faircloth <[EMAIL PROTECTED]>
> wrote:
>
>   
>> I remember getting that error when trying to complete a
>> long-running cfftp request.
>>
>> It's been awhile, and I'm not sure what actually solved the issue,
>> but I did look back at the file and remember adding
>> 
>> to the code at the top of the page.
>>
>> Perhaps setting a high requesttimeout will help.
>>
>> If I think of something else, I'll pass it on to you.
>>
>> Rick
>>
>> 
>>> -Original Message-
>>> From: Randy Johnson [mailto:[EMAIL PROTECTED]
>>> Sent: Sunday, April 13, 2008 12:15 AM
>>> To: CF-Talk
>>> Subject: weird issue in browser with cf8 and long execution times
>>>
>>> Hello,
>>>
>>> I am running CF8 Standard.
>>>
>>> I am running a page that takes a few minutes to run.   After a certain
>>> amount of time a gray box will popup and ask me to save the index.cfm
>>>   
>> file
>> 
>>> or open it.  When I open it or save it the file is always blank.
>>>
>>> When this happens it looks like the page is done executing in the
>>>   
>> browser
>> 
>>> but if you look in the task manager you see that JRUN is still using the
>>> CPU.  I have also confirmed that the page is still running by doing a
>>> refresh in Navicat which shows that more rows are being added to the
>>> database table.
>>>
>>> The page is reading an XML file, parsing it and then looping over to
>>>   
>> insert
>> 
>>> data into the database.
>>>
>>> Has anyone seen this before or know what I need to do to stop it from
>>> happening?
>>>
>>>
>>> Thanks!
>>>
>>> Randy
>>>
>>>
>>>
>>>   
>> 
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303267
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: CFID and CFTOKEN in the way

2008-04-13 Thread rex
btw, can you point us to the Forta article?

Les Mizzell wrote:
> Dan Vega wrote:
>   
>> When using cflocation you can set the attribute for addtoken="false"
>> 
>
> Yea - but it's often a form submission without a cflocation.
>
> I found a method suggested by Ben Forta I'm playing with...
>
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303266
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4


Re: CFID and CFTOKEN in the way

2008-04-13 Thread rex
the CFID/CFTOKEN is only appended to the URL if you are using 
URLSessionFormat() or if in the form tag, there is no method set, or it 
is set to GET, or it is set in the action page

no simple way, but you need to remove them in all the places landing 
onto the barclay page

or you can add CFID/CFTOKEN as the approved url in the barclay admin

Les Mizzell wrote:
> Dan Vega wrote:
>   
>> When using cflocation you can set the attribute for addtoken="false"
>> 
>
> Yea - but it's often a form submission without a cflocation.
>
> I found a method suggested by Ben Forta I'm playing with...
>
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303265
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: cf8 Admin error handler url

2008-04-13 Thread rex
/myapp is probably a mapping or a customtag/component location that has 
not been set up

the myapp referenced in the CF Admin error handler is not a directory in 
your application, but a coldfusion mapping

you can add the mapping "/myapp" to point to your absolute path 
"C:\WHEREVERYOURWEBROOTIS\myapp"

That way, CF can properly find your "myerrorhandler.cfm" file

Thanks!

George Lu wrote:
> It looks like if I put ip address instead of DNS name/server name it'll work
> (i.e. http://serveripaddress/myapp/myscheduledtask.cfm). I just don't know
> why.
>
> On 12/04/2008, George Lu <[EMAIL PROTECTED]> wrote:
>   
>> I've got the same issue in Scheculed Tasks. If I put
>> http://servername/myapp/index_mysite.cfm in the task CF Admin will throw a
>> 500 error. It looks like "http://servername/..."; and "
>> http://servername:8301/..."; are in different application scope?
>>
>> On 11/04/2008, George Lu <[EMAIL PROTECTED]> wrote:
>> 
>>> I've just set up a cluster with two instances. I've got an error handler
>>> worked in the past. Now put it same url as before e.g.
>>> "/myapp/myerrorhandler.cfm". The CF Admin comes up with an error: "The file
>>> specified as the site wide error handler does not exist.". The instance
>>> admin url start with 
>>> http://servername:8301/CFIDE/....
>>> My app is in IIS web root. Is there any way I can specify the correct path
>>> to the error handler?
>>>
>>> Please help.
>>>
>>> George
>>>
>>>   
>> 
>
>
> 

~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;192386516;25150098;k

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:303264
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4


Re: Hosting question

2002-10-02 Thread Rex Wickham

Hi
Take a look at www.coldfusionhosts.net

It's got lots of hosting companies listed. Could be a useful starting
point..

Rex
Coldfusionhosts admin

- Original Message -
From: "Kris Pilles" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Wednesday, October 02, 2002 3:56 PM
Subject: OT: Hosting question


I am looking to expand my hosting customer base and I am curious if
anyone knows of where I can either buy accounts from an existing hosting
company or buy a hosting company etc..any sort of input would be
greatly appreciated.

I am having no luck in the search engines looking for anything like this

Kris Pilles
Website Manager
Western Suffolk BOCES
507 Deer Park Rd., Building C
Phone: 631-549-4900 x 267
E-mail: [EMAIL PROTECTED]



~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.



Re: Mildly OT: CF MX Hosting

2002-09-26 Thread Rex Wickham

Hi
Try www.coldfusionhosts.net

It's a worldwide search engine for ColdFusion hosts.

Hope that helps.

Regards

Rex
Site webmaster.

- Original Message -
From: "Russ" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, September 26, 2002 2:59 PM
Subject: Mildly OT: CF MX Hosting


Hi All,

I've sifted through the last week or so that I've been on the list and I
haven't seen too much about this topic, and I'm hoping to find a
reasonably priced host for my own business site (color me independent as
I join the ranks of the unemployed; I guess it's either sit still or
die), as well as a decent reseller option.

So far, ExpertHost (www.experthost.com) seems to be a very solid,
logical option based upon positioning at The Hub, and based upon their
package price, but I'd certainly appreciate any insight.

Thanks in advance,

Russ


__
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Re: CFMX Hosting

2002-09-19 Thread Rex Wickham

Try www.coldfusionhosts.net

A complete search engine for CF hosts.

Refards

Rex

- Original Message -
From: "Tangorre, Michael" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, September 19, 2002 12:27 PM
Subject: CFMX Hosting


Hello all,

Anyone know of some relatively inexpensive CF Hosting. It is for a hobby
site of mine that I am working on. I initially was going to just host it
from my apartment, but Comcast doesnt appreciate the traffic generated from
the Message boards I have there. :-) Also, since I can not afford to buy
CFMX to run, I am looking for some good hosting that is realtively cheap
whatever cheap might be.  :-)

Thanks.

Mike

__
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



Re: CF Host in Seattle Area

2002-09-17 Thread Rex Wickham

Hi
Take a look at www.coldfusionhosts.net
its a search engine for Coldfusion hosting providers

Regards

Rex
coldfusionhosts.net admin

- Original Message -
From: "Ian Lurie" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Tuesday, September 17, 2002 5:22 PM
Subject: CF Host in Seattle Area


Anyone know a good, ColdFusion host in the Seattle metro area? We'd be
setting up a rack...

TIA

Ian Lurie

Portent Interactive
Helping clients build customer relationships on the web since 1995
Consulting, design, development, measurement
http://www.portentinteractive.com
http://www.searchengineoptimization.cc


__
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists



ColdFusion Host search engine

2002-08-30 Thread Rex Wickham

Hi
I've recently started a website www.coldfusionhosts.net which is a search
engine for good ColdFusion hosting companies. If any of you would liike to
recommend a host for this search engine, please get in touch. If any of you
are hosting companies that offer ColdFusion, may I encourage you to visit
the site to add your details. Here's a link to add yourself:
http://www.coldfusionhosts.net/modules.php?name=Hosts&rop=write_review

Hopefully the site will be of use to developers like yourselves too. It will
contain news, reviews and downloads much like its sister site
www.javahosts.net which has been going strong for over a year now.

Regards

Rex
[EMAIL PROTECTED]


~|
Archives/subscription: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.



simple cfloop

2002-03-03 Thread Sorgatz, Rex

Beginner CFer with an easy question. The situation: the user selects the
rows to query based upon ticking checkboxes. So, this is the first page:







 

Using a list and a cfloop to return multiple columns in only the rows the
user selects, what would the tally.cfm page look like? I'm looking at
something like this, but I know it's wrong:



SELECT this, that, theotherthing
FROM tblName
WHERE ID = #id#
 
#this##that##theotherthing#


Thanks for your help.

__
Why Share?
  Dedicated Win 2000 Server · PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
  Instant Activation · $99/Month · Free Setup
  http://www.pennyhost.com/redirect.cfm?adcode=coldfusionc
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists