Re: date format fo mySql

2010-08-20 Thread Jim Eisenhauer

Is your field in the db set up as a DATE or DATETIME?

Jim Eisenhauer


On Fri, Aug 20, 2010 at 9:26 AM, Rob Voyle r...@voyle.com 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.

 Thanks

 Rob

 Robert J. Voyle, Psy.D.
 Director, Clergy Leadership Institute
 For Coaching and Training in Appreciative Inquiry
 Author: Core Elements of the Appreciative Way
 http://www.clergyleadership.com/
 503-647-2378 or 503-647-2382


 

~|
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:336443
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 Jim Eisenhauer

Where is the date you need to insert coming from as well?  A form? and/or is
it a literal string like 'Dec. 10, 2010'... or is the form field passing an
actual date variable?

Jim Eisenhauer


On Fri, Aug 20, 2010 at 9:28 AM, Jim Eisenhauer eisenha...@gmail.comwrote:

 Is your field in the db set up as a DATE or DATETIME?

 Jim Eisenhauer



 On Fri, Aug 20, 2010 at 9:26 AM, Rob Voyle r...@voyle.com 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.

 Thanks

 Rob

 Robert J. Voyle, Psy.D.
 Director, Clergy Leadership Institute
 For Coaching and Training in Appreciative Inquiry
 Author: Core Elements of the Appreciative Way
 http://www.clergyleadership.com/
 503-647-2378 or 503-647-2382


 

~|
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:336444
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: (ot) Site issue with Safari 5.01 on Mac

2010-08-15 Thread Jim Eisenhauer

Probably the Flash file that's causing the issues, I'd start looking there
(client side I mean).

Jim Eisenhauer


On Sun, Aug 15, 2010 at 5:44 PM, Rick Root rick.r...@gmail.com wrote:


 Hi all,

 We've got a user saying that their site is scred up on Safari 5.01 on
 Mac ... I don't have a Mac so I can't really test but it looks fine in
 every browser I can test on Windows, including Safari 5.01

 Here's the URL

 http://www.shsclassof76.com/

 Here's a screenshot of what he sees:


 http://forums.classcreator.com/attachment.cfm?file_id=62CAFFE0-EAD3-B4D3-F768FB4CA543E243

 Anyone got any suggestions?

 Rick

 

~|
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:336293
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: SMTP Relay

2010-07-29 Thread Jim Eisenhauer

We currently use a service from smtp2go.com and it has worked flawlessly.

Jim Eisenhauer


On Thu, Jul 29, 2010 at 2:57 PM, Donnie Carvajal 
donnie.carva...@transformyx.com wrote:


 We are getting rid of our internal email server and I will be losing my
 SMTP relay that Coldfusion is using for the server attribute in the CFMAIL
 tag.  Rest assured, the CFMAIL tag is pulling the SMTP server from
 ColdFusion Administrator.  What is everyone using for SMTP relay if you
 aren't running an SMTP server?

 Thanks,

 Donnie

 

~|
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:335875
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


cfinput 'datefield' always aligns to left?

2010-07-22 Thread Jim Eisenhauer

Please help.

I cannot get the input field to center in a table cell using 'td 
align=center' or using CSS.

I haven't even been able to put something in front of the field in the same 
cell either without the field forcing itself onto a new line and aligning 
itself left. 

Here is a snippet of code...

td align=rightstrongDate Authorized/strong/td
td colspan=3 align=center
cfinput
type=datefield
name=DT_AUTH
value=#DA#
mask=mm/dd/
validate=date
disabled=#disabled#/td



~|
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:335646
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Odd MySQL error...

2010-06-23 Thread Jim Eisenhauer

If looks like your server is getting random intermittent connection drops
from your MySQL server (I'm assuming it's remote)

You could just wrap what you are trying to do in a cftry tag with a
cfcatch that could prompt to refresh or however else you would want to
handle the issue.  Otherwise you are going to have to look deep in to whats
causing the random packet losses.

Jim Eisenhauer


~|
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:334780
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: How can you GetFileInfo for a datasource?

2010-06-23 Thread Jim Eisenhauer

This info is not made readily available unless you unlock it.

You need access to the database...

 Open the database
Go to tools--Options
Check the box under *show* that says *system Objects*. You will notice that
several new tables appear in table view with the prefix MSys -
MSysAccessObjects, MSysAces, MSysObjects, MSysQueries, MSysRelationships,
and there may be a few others depending on your version of Access.
Now Go to Tools--Security--User and Group Permissions
Select the MSysObjects table and check the box that says Read Data

Then...

Cfquery name=getSysData datasource=cfdocexamples
   SELECT UpdateDate FROM MSysObjects
/CFQUERY

   cfdump var=#getSysData#




Jim Eisenhauer


~|
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:334786
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: How can you GetFileInfo for a datasource?

2010-06-23 Thread Jim Eisenhauer

In your query you might want to

SELECT Max(UpdateDate)

Sorry =)

Jim Eisenhauer


~|
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:334787
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Going nuts with a query

2010-06-15 Thread Jim Eisenhauer

Replace...

cfset newcsvfile = replace(newcsvfile, '', '', ALL)

with

cfset newcsvfile = replace(newcsvfile, '', ',', ALL)

You are missing your delimiter on that string.

You could also replace your double quotations with some other character you
wont see in your csv file, like ~ and add it to your delimeters list in
your loop.


Jim Eisenhauer


On Tue, Jun 15, 2010 at 2:17 PM, Phillip Vector
vec...@mostdeadlygame.comwrote:


 I have the following code
Insert into Accounting_Temp
(
Id
,EnrollmentNumber
,EnrollmentChannel
,StatusName
,Status
,PromoCode
,QualificationType
,CreationDate
,LastModified
,State
,ZipCode
,UnqualifiedReason
)
Values
(
cfloop index=data list=#i#
 delimiters=XX
cfswitch expression=#count#
cfcase value=1
'#data#'
/cfcase
cfcase value=2
, #data#
/cfcase
cfcase value=3
, '#data#'
/cfcase
cfcase value=4
, '#data#'
/cfcase
cfcase value=5
, #data#
/cfcase
cfcase value=6
, '#data#'
/cfcase
cfcase value=7
, '#data#'
/cfcase
cfcase value=8
cfset DBDate =
 #CREATEODBCDATETIME(data)#
, #DBDate#
/cfcase
cfcase value=9
cfset DBDate =
 #CREATEODBCDATETIME(data)#
, #DBDate#
/cfcase
cfcase value=10
, '#data#'
/cfcase
cfcase value=11
, '#data#'
/cfcase
cfcase value=12
cfif data is 'N/A'
cfset
 LongReasonFlag = 0
, '#data#'
cfelse
cfset
 LongReasonFlag = 1
, '#data#
/cfif
/cfcase
cfcase value=13
#data#
/cfcase
cfcase value=14
#data#
/cfcase
cfcase value=15
#data#
/cfcase
/cfswitch

Re: Going nuts with a query

2010-06-15 Thread Jim Eisenhauer

Replace...

cfset newcsvfile = replace(newcsvfile, '', '', ALL)

with

cfset newcsvfile = replace(newcsvfile, '', ',', ALL)

You are missing your delimiter on that string.

You could also replace your double quotations with some other character you
wont see in your csv file, like ~ and add it to your delimeters list in
your loop.

Jim Eisenhauer


~|
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:334590
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Slow cfqueryparam IN clause on SQL Server 2008

2010-06-14 Thread Jim Eisenhauer

Can you provide more of a snippet of code?

Jim Eisenhauer


On Mon, Jun 14, 2010 at 9:54 AM, Matthew Lesko m.le...@verizon.net wrote:


 Wondered if anyone else had experienced this. I have an IN clause query
 which runs in 500ms if I use cfqueryparam list=true. This same query runs
 in less than 10ms if I pass the values directly (e.g. 'value1', 'value2',
 etc...).

 I've Googled around a bit and have the impression it's an issue with how
 the statement is prepared on the db server, but couldn't find any solutions
 that allowed for using cfqueryparam.

 Anyone have experience solving this problem?

 

~|
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:334536
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Bizarre capitalisation issue with bookmarkTitles in CFPDF with DDX

2010-06-14 Thread Jim Eisenhauer

Another thing to try would be (off your first attempt to resolve)...

PDF source=Cover bookmarkTitle=#Replace('ucase('Co')','O','o','all')#ver
Page/


What happens just passing as a string with no Ucase()?

Like...
cfset bookmarkTitle = 'Cover Page'
PDF source=Cover bookmarkTitle=#bookmarkTitle#/

This still should produce the same issue, but being as that it may be a bug,
this might work as a bandaid.

Jim Eisenhauer


On Mon, Jun 14, 2010 at 2:57 PM, Raymond Camden rcam...@gmail.com wrote:


 That's all I can suggest for now - if it works in 9 it may be worth
 the price of the update.

 On Mon, Jun 14, 2010 at 4:19 PM, adam sontag ajpi...@ajpiano.com wrote:
 
  Still on 8.0.1.  Nothing in the second hotfix for 8 addressed anything
 about this, and I haven't had a chance to test this on 9 yet.
 
  Smells like a bug for sure. What version of CF?
 
 
  On Mon, Jun 14, 2010 at 4:00 PM, adam sontag ajpi...@ajpiano.com
  wrote:
  
   Hi everyone,
  
   I have encountered an issue that can only be described as extremely
  bizarre, and am curious if anyone has encountered it before.  I am
  generating a PDF using DDX instructions, merging a bunch of pdfs
  together, creating a cover page using CFDocument, adding bookmarks,
  the whole spiel.  I was pretty much done, but I figured, hey, let me
  put a bookmark for the cover page in.  Surely enough, when I try to
  make the text of the bookmark be Cover Page, CF inexplicably makes
  the first 'C' be lower case.  This does not affect any other letters
  of the alphabet.
  
  --
  ==
 =
  Raymond Camden, ColdFusion Jedi Master
 
  Email: r...@camdenfamily.com
  Blog  : www.coldfusionjedi.com
  AOL IM : cfjedimaster
 
  Keep up to date with the community: http://www.
  coldfusionbloggers
 
 

 

~|
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:334550
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Date range with a date in the past

2010-06-13 Thread Jim Eisenhauer

WHERE EventStartDate= #now()# AND EventFinishDate= #now()#

You had your end date looking for a date = Now()

Jim Eisenhauer


On Sun, Jun 13, 2010 at 6:41 PM, Roger Austin raust...@nc.rr.com wrote:


 On 6/13/2010 9:30 PM, Kevin Parker wrote:
 
  Greatly appreciate another set of eyes looking at this please.
 
  Picking events from a table based on dates so that only current or future
  events show up. Date values can not be NULL.
 
  (EventStartDate= #now()#) AND (EventFinishDate= #now()#)
 
  Let's say an event runs from 17/6 to 19/6 things work OK today but on the
  18/6 this event will drop off the calendar even though it's still
 running.
 
  Greatly appreciate any insight - TIA

 Why do you have the first condition?

 Anyway, wouldn't this be an OR?

 --
 LinkedIn: http://www.linkedin.com/pub/8/a4/60
 Twitter:  http://twitter.com/RogerTheGeek
 MissHunt: http://www.misshunt.com/ (Home of the Clean/Dirty Magnet)
 NCDevCon: http://ncdevcon.com/ 2010 Raleigh ColdFusion Conference

 

~|
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:334521
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: How to loop over a dataset twice.

2010-06-09 Thread Jim Eisenhauer

..and if you can't you should probably be using 2 different queries.

Jim Eisenhauer


On Wed, Jun 9, 2010 at 5:46 AM, Michael Grant mgr...@modus.bz wrote:


 
  And I'm willing to bet that whatever you're doing, you can do it in one
  loop, too :)
 

 100% agree.


 

~|
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:334405
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: Query of queries question

2010-06-09 Thread Jim Eisenhauer

Your first issue is that that is not a good db practice naming columns as
numbers.  If you put a prefix of y in front of the column name in your
table (or whatever you chose, i.e y1990, y1991, y1992) it wouldn't have this
issue, it would force your SQL to actual look for a table column rather than
just summing the number you entered.  In some databases you can force the
issue by surrounding the column header in quotations (Sum('1990')) but you
cannot count on that, you are better off renaming your column headers as I
said earlier.

Jim Eisenhauer


On Wed, Jun 9, 2010 at 8:27 AM, fun and learning funandlrnn...@gmail.comwrote:


 HI All -

 I have a query which returns the result set like below. The column names
 are like 1990, 1991, 1992 and there are certain amount for each year

 1990 1991 1992
 1000 5000 6000
 2000 2000 3000

 I have a query of query which finds the sum of the amounts for year 1990,
 and I use the query like Select SUM(1990), it returns the sum of 1990+1990.
 How to make sure that 1990 is recognized as a column instead as a number.

 Thanks

 

~|
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:334411
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm


Re: How to loop over a dataset twice.

2010-06-08 Thread Jim Eisenhauer

What you have spelled out is very vague and may or may not be possible without 
knowing more about the functions you are trying to perform.

Please provide more information on what you are trying to do. 

~|
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:334397
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm