Re: payment gateway options

2010-04-28 Thread Matthew P. Smith

The chances of chargebacks is slim to none; I would be HIGHLY surprised if
there ever was a single one.  This is for customers under contract for a
service, who are already happily paying monthly.  We just want to give them
a way to pay online, rather than by check.

This is for a corporate entity, and the top people balked when told they
would have to be guarantors.  Maybe the corporate officers don't understand
what they are agreeing to.  I suppose I could have something in the proposal
that explores the issue and makes it less scary, but at this point I would
like to provide the information they asked for, one of the requirements
being no guarantors.

Perhaps if I could find a gateway that will discuss the option of both, I
could present the price difference between the two and let them decide.  I
just need to know who will do it so I can start the dialog.

Thank you.


On Wed, Apr 28, 2010 at 11:37 PM, Justin Scott  wrote:

>
> > Now, here is the thing:  The client REFUSES to sign
> > as a guarantor on the account.
>
> As an aside, HUGE red flag there.  Why won't they guarantee their own
> merchant account?  Are they expecting high rates of complaints or
> chargebacks?  If they won't do it, you certainly should NOT do it for them.
> Many merchant providers won't service a new business without a guarantor,
> and those that will are going to be looking hard at the kinds of products
> they sell to gauge risk and you can expect higher fees and percentages or
> even a reserve balance requirement as a result.
>
>
> -Justin
>
>
>
> 

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


RE: payment gateway options

2010-04-28 Thread Justin Scott

> Now, here is the thing:  The client REFUSES to sign
> as a guarantor on the account.

As an aside, HUGE red flag there.  Why won't they guarantee their own
merchant account?  Are they expecting high rates of complaints or
chargebacks?  If they won't do it, you certainly should NOT do it for them.
Many merchant providers won't service a new business without a guarantor,
and those that will are going to be looking hard at the kinds of products
they sell to gauge risk and you can expect higher fees and percentages or
even a reserve balance requirement as a result.


-Justin



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


RE: payment gateway options

2010-04-28 Thread Justin Scott

> Looking for a payment gateway that offers a low
> transaction cost/percentage per sale.  These will
> be high-value transaction, ~1000 monthly per
> customer.

It's a messy world out there in transaction processing land.  In addition to
the direct fees and percentages, consider your PCI compliance costs as well.
In my experience, no matter who your merchant account is through or what
gateway provider you use, you're going to get hit with something unexpected
that costs extra (statement fees anyone?).

We're actually considering switching processing on some of our sites over to
Braintree.  I haven't used their service yet, but in speaking with them they
appear to be very straightforward.  Their pricing is a little higher than
some, but the way they handle transactions takes the web site out of scope
for PCI compliance which more than makes up the difference in cost savings
on that front.  If we end up moving forward with them I'll let everyone know
how it goes.  If anyone lurking has experience with them I'd be interested
in hearing how it's going.

http://www.braintreepaymentsolutions.com/pricing


-Justin



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


payment gateway options

2010-04-28 Thread Matthew P. Smith

Looking for a payment gateway that offers a low transaction cost/percentage
per sale.  These will be high-value transaction, ~1000 monthly per customer.

The standard paypal pricing is between %1.9 and %2.9, which is quite a bit.

I looked at authorize.net, and they are charging only $0.10/transaction with
no mention of a percentage.  Is that right?

Now, here is the thing:  The client REFUSES to sign as a guarantor on the
account.  So I need a solution that will allow the service without that.

Options?

Thanks!


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


Re: store image location in database

2010-04-28 Thread Kevin Pepperman

Once you have inserted the filname into your database, you would get the
filename by querying the database with the Primary Key set on the image in
the table.

Assuming the table was like this.

* imageID | imageName*
* -*
*  1 | /mypath/myimage1.jpg*
*  2 | /mypath/myimage2.jpg*
*  3 | /mypath/myimage3.jpg*
*  4 | /mypath/myimage4.jpg*

And you have inserted the names into your table with SQL


**
*INSERT INTO myImagetable (imageName)*
*VALUES*
*()*
**



You then would use a URL with the tables ID to get the filename:


eg. */index.cfm?imageId=1*

*
*

Then use the URL.imageid in the query to get the filename:

**
*SELECT imageName FROM myImageTable*
*WHERE imageId = LIMIT 1*
**



Then use the query result in the image src attribute.


**

*
*
*
*

Is that what you are asking for?

-- 
/Kevin Pepperman

"They who can give up essential liberty to obtain a little temporary safety,
deserve neither liberty nor safety." - Benjamin Franklin


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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread James Holmes

You can of course avoid the whole issue by using the result_name.IDENTITYCOL
value returned from the cfquery tag (if you are on CF8 or higher).

mxAjax / CFAjax docs and other useful articles:
http://www.bifrost.com.au/blog/


On 29 April 2010 01:51, Che Vilnonis  wrote:

>
> When using "set nocount on", "select @@identity as xyz" and "set nocount
> off" in a cfquery, how can I be certain that two transactions that occur at
> roughly the same time obtain the proper incremental id from an Identity
> column? Is their a SQl equivalent to CF's cflock tag?
>
> Thanks, Che
>
>
>
>
> 

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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Leigh _

>YO!  2005 +
>
>USE OUTPUT Duh!

Yes, if needed, OUTPUT is an option as well. (Though IIRC it does not work with 
the jTDS driver. At least not the last time I checked.) However, the primary 
point was there are safer alternatives to SELECT MAX(ID) ..


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


Re: Using two submit buttons to control form action

2010-04-28 Thread Rob Parkhill

You will need to have a different name, and then check that value. Since
your buttons both have the same name, the value for both will be in the form
scope as you have seen.


 I always just do a regular button, and change the form action via
Javascript.

Cheers,

Rob

On Wed, Apr 28, 2010 at 8:24 PM, John Pullam wrote:

>
> I have seen several examples of using multiple form buttons on a single
> form. The idea is that you can get the value of the respective form variable
> when you are posted and then take the appropriate action.
>
> But I'm getting odd results. Instead of getting a single value, I get both
> values every time, and the examples I've seen suggest that you should only
> get the one that was pressed.
>
> Can anyone tell me what I'm doing wrong or what I need to do to get a
> single value? My code for the buttons is as follows:
>
> 
> 
>
> When I CFDump it, FORM.Choose is Change,Full
>
>
> 

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


Re: Using two submit buttons to control form action

2010-04-28 Thread Maureen

You're getting that result because both buttons have the same name.

On Wed, Apr 28, 2010 at 5:24 PM, John Pullam  wrote:

> Can anyone tell me what I'm doing wrong or what I need to do to get a single 
> value? My code for the buttons is as follows:
>
> 
> 
>
> When I CFDump it, FORM.Choose is Change,Full

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


RE: Using two submit buttons to control form action

2010-04-28 Thread Justin Scott

> I have seen several examples of using multiple form
> buttons on a single form. The idea is that you can
> get the value of the respective form variable when
> you are posted and then take the appropriate action.

Usually that's triggered by the name of the form button that was clicked,
not the value.  For example, you might have two buttons:




On your processing page...


  

  


...and so on.  With HTML forms, if two or more form elements have the same
name, the values of all active form elements with that name will be put into
a comma-delimited list and show up in ColdFusion as a single variable with a
list of values, as you experienced.  This is great for checkboxes (getting a
list of the ones that were checked that share a name), but not so great for
submit buttons.


-Justin



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


Re: Using two submit buttons to control form action

2010-04-28 Thread Dan Baughman

I'm using cf9 on iis7 and when I put what you've provided into a form,
form.choose is either equal to change, or full, depending on which button
was clicked.

On Wed, Apr 28, 2010 at 6:24 PM, John Pullam wrote:

>
> I have seen several examples of using multiple form buttons on a single
> form. The idea is that you can get the value of the respective form variable
> when you are posted and then take the appropriate action.
>
> But I'm getting odd results. Instead of getting a single value, I get both
> values every time, and the examples I've seen suggest that you should only
> get the one that was pressed.
>
> Can anyone tell me what I'm doing wrong or what I need to do to get a
> single value? My code for the buttons is as follows:
>
> 
> 
>
> When I CFDump it, FORM.Choose is Change,Full
>
>
> 

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


Using two submit buttons to control form action

2010-04-28 Thread John Pullam

I have seen several examples of using multiple form buttons on a single form. 
The idea is that you can get the value of the respective form variable when you 
are posted and then take the appropriate action.

But I'm getting odd results. Instead of getting a single value, I get both 
values every time, and the examples I've seen suggest that you should only get 
the one that was pressed.

Can anyone tell me what I'm doing wrong or what I need to do to get a single 
value? My code for the buttons is as follows:




When I CFDump it, FORM.Choose is Change,Full 


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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Casey Dougall

On Wed, Apr 28, 2010 at 6:19 PM,  wrote:

> Yes, I would agree that is a much simpler and safer alternative.  since
> scope_identity() is already specific to your connection you don't have
> to worry about locking and such altogether.
>
> ~Brad
>
>  Original Message 
> Subject: Re: SQL Gurus... obtaining the correct Incremental ID
> From: Leigh _ 
> Date: Wed, April 28, 2010 4:44 pm
> To: cf-talk 
>
>
> >That would ONLY work if you used SET TRANSACTION ISOLATION LEVEL
> >SERIALIZABLE or WITH(TABLOCKX HOLDLOCK)
> >
> >Even with with rowlock, another spid can insert additional records into
> >the table and the select max() might return a bogus value.
>
> Aside from being unsafe without the right isolation level, it is not
> necessary in MSSQL 2005 or CF8+. As use mentioned use SCOPE_IDENTITY()
> or cfquery's result attribute.
>

YO!  2005 +

USE OUTPUT Duh!

http://msdn.microsoft.com/en-us/library/ms177564.aspx

OUTPUT Clause (Transact-SQL)

Returns information from, or expressions based on, each row affected by an
INSERT, UPDATE, DELETE, or MERGE statement. These results can be returned to
the processing application for use in such things as confirmation messages,
archiving, and other such application requirements. The results can also be
inserted into a table or table variable. Additionally, you can capture the
results of an OUTPUT clause in a nested INSERT, UPDATE, DELETE, or MERGE
statement, and insert those results into a target table or view.


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


store image location in database

2010-04-28 Thread Remus Suciu

Greetings all, from a noob.
I'm trying to figure out how to upload a file and store its name and location 
into a database for subsequent retrieval.
I will append the code below, but I will say this: it uploads pictures, and 
stores their names into the db.  I just don't know how to get CF to get the 
file location once I've updated and then add that to the DB.







Upload An Image


 












 



 

Click the confirm button to insert into the database










  


 


You inserted the image name #Form.Title# 
in to your database.
Upload another image.


 

 

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


RE: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread brad

> Wouldn't READ COMMITTED do the trick? ...will never read data that another 
> application has changed and not yet committed 

No.  Another process could insert a record into the table and commit its
change before you select out the max.  The ONLY way for the max() record
to be yours is to prevent ALL OTHER processes from touching the table. 
Or, just make life easy on yourself and use scope_identity().  

~Brad



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


cfchart ignores my scalefrom value

2010-04-28 Thread Monte Chan

Hi all,

I have the following codes in my page.

The style variable holds the custom style.  The custom style is quite big and I 
am not going to post all the codes here unless I absolutely have to.

  
  
  

The strange thing is, when there are two or more MyScore values, the chart 
displays as expected.  However, when there is only 1 MyScore value, the chart 
would show 0 to 100 in the y-axis.  It would still show 9 grid lines but these 
lines are displayed from 0 to 100 instead of from 20 to 100.

Does anyone know why this is happening?  I am running CF 9 on WinXP on my local 
box.

Thanks in advance,
Monte


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


RE: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread brad

I'm on 8.0.1 and it appears that CF doesn't override the default SQL
Server isolation level if you don't specify one in your cftransaction
tag.

I ran the following code whilst tracing:


select *
from table



This is what I got:

SET IMPLICIT_TRANSACTIONS ON
select * from test
IF @@TRANCOUNT > 0 COMMIT TRAN
IF @@TRANCOUNT > 0 COMMIT TRAN SET IMPLICIT_TRANSACTIONS OFF
SET TRANSACTION ISOLATION LEVEL READ COMMITTED
SET TRANSACTION ISOLATION LEVEL READ COMMITTED

When I added isolation="serializable" to the cftransaction tag, I get
"SET TRANSACTION ISOLATION LEVEL SERIALIZABLE" immediately prior to the
select.

~Brad



 Original Message 
Subject: Re: SQL Gurus... obtaining the correct Incremental ID
From: Dave Watts 
Date: Wed, April 28, 2010 4:54 pm
To: cf-talk 


> That would ONLY work if you used SET TRANSACTION ISOLATION LEVEL
> SERIALIZABLE or WITH(TABLOCKX HOLDLOCK)

This is one of those things I never am completely clear on, but I
believe that the default isolation level for CFTRANSACTION is
serializable in CF 7+.

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.



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


RE: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread brad

Yes, I would agree that is a much simpler and safer alternative.  since
scope_identity() is already specific to your connection you don't have
to worry about locking and such altogether.

~Brad

 Original Message 
Subject: Re: SQL Gurus... obtaining the correct Incremental ID
From: Leigh _ 
Date: Wed, April 28, 2010 4:44 pm
To: cf-talk 


>That would ONLY work if you used SET TRANSACTION ISOLATION LEVEL
>SERIALIZABLE or WITH(TABLOCKX HOLDLOCK)
>
>Even with with rowlock, another spid can insert additional records into
>the table and the select max() might return a bogus value.

Aside from being unsafe without the right isolation level, it is not
necessary in MSSQL 2005 or CF8+. As use mentioned use SCOPE_IDENTITY()
or cfquery's result attribute. 



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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread nvc 1

from cfquickdocs for cf8: "If you do not specify a value for the isolation 
attribute, ColdFusion uses the default isolation level for the associated 
database."

from mssqlcity.com: "READ COMMITTED
This is the default isolation level in SQL Server. When it's used, SQL Server 
will use shared locks while reading data. It ensures that a physically corrupt 
data will not be read and will never read data that another application has 
changed and not yet committed, but it not ensures that the data will not be 
changed before the end of the transaction."

Wouldn't READ COMMITTED do the trick? ...will never read data that another 
application has changed and not yet committed 

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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Casey Dougall

On Wed, Apr 28, 2010 at 5:34 PM, nvc 1  wrote:

>
> so is this reliable?
>
>
>
> 
>insert into mytable(acolumn)   values(1)
>
>
>select max(id) as maxid from mytable
>
>
>
>

It's way simpler!

This is totally transaction safe since you are only interested in the ID
form "one" table not many and are running MS SQL server 2005 or above. On
2000 you can't use output clause.


  INSERT INTO TableName
   (Stuff)
   OUTPUT inserted.ID, inserted.Stuff
  VALUES
   ()




As you see, you can output any column you just inserted, and they are
returned in a query


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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Leigh _

>That would ONLY work if you used SET TRANSACTION ISOLATION LEVEL
>SERIALIZABLE or WITH(TABLOCKX HOLDLOCK)
>
>Even with with rowlock, another spid can insert additional records into
>the table and the select max() might return a bogus value.

Aside from being unsafe without the right isolation level, it is not necessary 
in MSSQL 2005 or CF8+. As use mentioned use SCOPE_IDENTITY() or cfquery's 
result attribute. 

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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread nvc 1

so is this reliable?


  
   
insert into mytable(acolumn)   values(1) 
  
   
select max(id) as maxid from mytable 
 
 

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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Dave Watts

> That would ONLY work if you used SET TRANSACTION ISOLATION LEVEL
> SERIALIZABLE or WITH(TABLOCKX HOLDLOCK)

This is one of those things I never am completely clear on, but I
believe that the default isolation level for CFTRANSACTION is
serializable in CF 7+.

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.

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


Re: cfcatch issue

2010-04-28 Thread Dave Watts

> I am using try/catch around a cfquery, and when I use #cfcatch.SQl# within 
> cfcatch, I get an error saying sql is undefined
> in cfcatch. The same happens with #cfcatch.where#. Everything is fine with 
> #cfcatch.detail#, #cfcatch.message#.
>
> I have been working with #cfcatch.sql# and #cfcatch.where# with no issues 
> until today. Can any one let me know what could be
> the issue

Those variables will only be available if the thrown exception is of
TYPE="DATABASE". So check your CFCATCH.TYPE to see if that's what you
have.

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.

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


RE: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread brad

Transactions control when data gets committed as well as how long some
locks are held.  They do not necessarily keep other processes from
modifying parts of a table you are touching.  That's when isolation
levels and locking behavior comes into play.

~Brad

 Original Message 
Subject: RE: SQL Gurus... obtaining the correct Incremental ID
From: "Che Vilnonis" 
Date: Wed, April 28, 2010 3:59 pm
To: cf-talk 


I am using the cftransaction tags. Honestly, I was not absolutely sure
that
I needed to do anything else and that is why I posted my original
question.



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


RE: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread brad

That would ONLY work if you used SET TRANSACTION ISOLATION LEVEL
SERIALIZABLE or WITH(TABLOCKX HOLDLOCK)

Even with with rowlock, another spid can insert additional records into
the table and the select max() might return a bogus value.

~Brad


 Original Message 
Subject: Re: SQL Gurus... obtaining the correct Incremental ID
From: nvc 1 
Date: Wed, April 28, 2010 3:14 pm
To: cf-talk 


why can't you do this where mytable has an auto incrementing primary key
called id:



 
 insert into mytable(acolumn)
 values(1)
 

 
 select max(id) as maxid from mytable
 

 



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


Re: sql method in cfcatch

2010-04-28 Thread Barney Boisvert

The error you're catching might not have those properties.  For
example, maybe it's a connection failure error.  Or perhaps an
expression error in a CFQUERYPARAM.  Those keys will be present when
appropriate, but they're not necessarily available all the time.  As
such, you have to do existence checks before you use them.

cheers,
barneyb

On Wed, Apr 28, 2010 at 1:11 PM, fun and learning
 wrote:
>
> Hi All -
>
> I am using try/catch around a cfquery. When I am trying to output 
> #cfcatch.sql# or #cfcatch.where#, I get an error that SQl or where is 
> undefined in cfcatch. These two used to work for me before. I have no issues 
> with cfcatch.message or cfcatch.detail.
>
> Can anyone let me know what could be the issue?
>
>
>
> 

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


RE: cfcatch issue

2010-04-28 Thread Paul Alkema

Are you on CF8 or higher? Try dumping the cfcatch scope and see what you
get.

Paul Alkema
PaulAlkema.com

-Original Message-
From: fun and learning [mailto:funandlrnn...@gmail.com] 
Sent: Wednesday, April 28, 2010 4:26 PM
To: cf-talk
Subject: cfcatch issue


hi all- 

I am using try/catch around a cfquery, and when I use #cfcatch.SQl# within
cfcatch, I get an error saying sql is undefined
in cfcatch. The same happens with #cfcatch.where#. Everything is fine with
#cfcatch.detail#, #cfcatch.message#.

I have been working with #cfcatch.sql# and #cfcatch.where# with no issues
until today. Can any one let me know what could be
the issue 



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


RE: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Che Vilnonis

I am using the cftransaction tags. Honestly, I was not absolutely sure that
I needed to do anything else and that is why I posted my original question.

-Original Message-
From: nvc 1 [mailto:n...@hotmail.co.uk] 
Sent: Wednesday, April 28, 2010 4:14 PM
To: cf-talk
Subject: Re: SQL Gurus... obtaining the correct Incremental ID


why can't you do this where mytable has an auto incrementing primary key
called id:



 
  insert into mytable(acolumn)
  values(1)
 

 
  select max(id) as maxid from mytable
 

 



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


cfcatch issue

2010-04-28 Thread fun and learning

hi all- 

I am using try/catch around a cfquery, and when I use #cfcatch.SQl# within 
cfcatch, I get an error saying sql is undefined
in cfcatch. The same happens with #cfcatch.where#. Everything is fine with 
#cfcatch.detail#, #cfcatch.message#.

I have been working with #cfcatch.sql# and #cfcatch.where# with no issues until 
today. Can any one let me know what could be
the issue 

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


sql method in cfcatch

2010-04-28 Thread fun and learning

Hi All -

I am using try/catch around a cfquery. When I am trying to output #cfcatch.sql# 
or #cfcatch.where#, I get an error that SQl or where is undefined in cfcatch. 
These two used to work for me before. I have no issues with cfcatch.message or 
cfcatch.detail.

Can anyone let me know what could be the issue?



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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread nvc 1

why can't you do this where mytable has an auto incrementing primary key called 
id:



 
  insert into mytable(acolumn)
  values(1)
 

 
  select max(id) as maxid from mytable
 

 

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


RE: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Che Vilnonis

Dave/Barney/Casey... I'm using SQL 2005.
I just wanted to cover all bases and was looking for a code snippet. Thanks.

-Original Message-
From: Casey Dougall [mailto:ca...@uberwebsitesolutions.com] 
Sent: Wednesday, April 28, 2010 2:13 PM
To: cf-talk
Subject: Re: SQL Gurus... obtaining the correct Incremental ID


On Wed, Apr 28, 2010 at 1:51 PM, Che Vilnonis  wrote:

>
> When using "set nocount on", "select @@identity as xyz" and "set 
> nocount off" in a cfquery, how can I be certain that two transactions 
> that occur at roughly the same time obtain the proper incremental id 
> from an Identity column? Is their a SQl equivalent to CF's cflock tag?
>
> Thanks, Che
>
>
 On MS SQL server I believe anyting above 2000 use the output clause


insert into table
(col1, col2, col3)

output inserted.ID

values
(col1Val,col2Val,col3Val)





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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Dave Watts

> Transactions, transactions, transactions. Don't write another line of
> SQL until you learn about transactions.

I really just want to second this. There should be a law. With
penalties including jail time for violation. (But perhaps time off
would be granted for understanding indexes.)

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

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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Casey Dougall

On Wed, Apr 28, 2010 at 1:51 PM, Che Vilnonis  wrote:

>
> When using "set nocount on", "select @@identity as xyz" and "set nocount
> off" in a cfquery, how can I be certain that two transactions that occur at
> roughly the same time obtain the proper incremental id from an Identity
> column? Is their a SQl equivalent to CF's cflock tag?
>
> Thanks, Che
>
>
 On MS SQL server I believe anyting above 2000 use the output clause


insert into table
(col1, col2, col3)

output inserted.ID

values
(col1Val,col2Val,col3Val)



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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Dave Watts

> When using "set nocount on", "select @@identity as xyz" and "set nocount
> off" in a cfquery, how can I be certain that two transactions that occur at
> roughly the same time obtain the proper incremental id from an Identity
> column? Is their a SQl equivalent to CF's cflock tag?

BEGIN TRANSACTION ... END TRANSACTION

If you're using a newer version of SQL Server, you may want to use
SCOPE_IDENTITY() instead of the @@IDENTITY global variable.

http://msdn.microsoft.com/en-us/library/ms190315.aspx

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.

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


Re: SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Barney Boisvert

Transactions, transactions, transactions.  Don't write another line of
SQL until you learn about transactions.

In this case it doesn't matter because @@identity is bound to the
active connection (and connections are single threaded), but you
should still be transactionally aware.

In addition to transactions, you can also do various types of locking
on the database to serialize access (exactly like CFLOCK), but they
obviously have performance and concurrency ramifications.
Transactions are typically a better way to solve it those types of
problems because their semantics are slightly different and can be
implemented in a more performant manner in most cases.

cheers,
barneyb

On Wed, Apr 28, 2010 at 10:51 AM, Che Vilnonis  wrote:
>
> When using "set nocount on", "select @@identity as xyz" and "set nocount
> off" in a cfquery, how can I be certain that two transactions that occur at
> roughly the same time obtain the proper incremental id from an Identity
> column? Is their a SQl equivalent to CF's cflock tag?
>
> Thanks, Che
>
>

-- 
Barney Boisvert
bboisv...@gmail.com
http://www.barneyb.com/

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


SQL Gurus... obtaining the correct Incremental ID

2010-04-28 Thread Che Vilnonis

When using "set nocount on", "select @@identity as xyz" and "set nocount
off" in a cfquery, how can I be certain that two transactions that occur at
roughly the same time obtain the proper incremental id from an Identity
column? Is their a SQl equivalent to CF's cflock tag?

Thanks, Che




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


Can't capture console output from MS util

2010-04-28 Thread Jon Sala

We've got a new AD server that refuses to cooperate with CFLDAP CF8 or CF9:
("Authentication failed:[LDAP: error code 49 - 80090308: LdapErr: 
DSID-0C090334, comment: AcceptSecurityContext error, data 525, vece ]")
However, I've been wrestling with that one long enough for now; I've got to 
move on.

The LDIFDE.EXE util on the other hand will get me the needed results from the 
AD - it however refuses to let me capture the console output (-f con) using 
cfexecute (tried au.com.webcode.util.SystemCommand as well).

I hate writing a temp file when I know the cfexecute variable="foo" attribute 
works perfectly in all the other code I've used it in.
I suspect it's something funky with ldifde, but I'm stumped!!


--
Jon


This message and any attached documents are only for the use of the intended 
recipient(s), are confidential and may contain privileged information. Any 
unauthorized review, use, retransmission, or other disclosure is strictly 
prohibited. If you have received this message in error, please notify the 
sender immediately, and then delete the original message. Thank you.

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


Re: HTTP Upload Problems

2010-04-28 Thread John Foster

The packet trace was run on an Amazon EC2 instance.  In this case 
169.254.169.254 is an internal Amazon IP that the EC2 instance uses to retrieve 
its metadata.  

The problems in the trace are these entries where "10.162.147.150" is the EC2 
instance and "Our Outside IP" is the upload server:

33457  408.67  10.162.147.150  Our Outside IP  HTTP  [TCP Retransmission] 
Continuation or non-HTTP traffic 



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


RE: CF8 sessions being dropped all of a sudden

2010-04-28 Thread brad

Start by using Fiddler to look at the cookie headers being sent to you
from the server and being sent back by your browser.  When your session
gets "dropped" does the server send you a new jsessionid cookie, or is
your browser still sending the same one.

Also, confirm your session time outs in the admin as well as the app to
make sure there is nothing screwy going on.

~Brad


 Original Message 
Subject: CF8 sessions being dropped all of a sudden
From: Steve Logan 
Date: Wed, April 28, 2010 7:53 am
To: cf-talk 


We have an application that's been working fine for 9+ years now
(started on CF5, now CF8.01). Yesterday we started to receive some
comments from users that they weren't able to log in. I could log into
their accounts fine, but they could not. They were using correct info (a
failed login attempt was not being logged). One was on Firefox, the
other on IE. In both cases, exiting and restarting the browser did the
trick.



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


CF8 sessions being dropped all of a sudden

2010-04-28 Thread Steve Logan

We have an application that's been working fine for 9+ years now (started on 
CF5, now CF8.01).  Yesterday we started to receive some comments from users 
that they weren't able to log in.  I could log into their accounts fine, but 
they could not.  They were using correct info (a failed login attempt was not 
being logged).  One was on Firefox, the other on IE.  In both cases, exiting 
and restarting the browser did the trick.

Now this morning it started happening to me and I was able to dump the cookie 
and session info.  What seemed to be happening was that the session variables 
to determine if a user was logged in, the user id, the login time etc. were 
being set correctly in the session, but when the user gets redirected via 
cflocation the session is reset.

In Application.cfm (yes I know - it's not an easy conversion to cfc - trust me 
- we're rewriting from the ground up because it's easier!), we have:

setclientcookies="Yes"

setdomain cookies is not specified.


We're setup in Admin to use JSESSIONID.  We're not changing from www.host.com 
to host.com when the user logs in.

Today I come in and see that our current users online is only 5 - it's normally 
about 20 at this time of day so I'm thinking this might be more widespread than 
originally thought.  We also have a few support e-mails where users can't login 
and don't get any sort of login failed error message.

No changes have been made to the server, application.cfm or login processes.  
The server was physically rebooted last night.

I've seen a few other posts on the web about this behavior but no concrete 
answer that fits our situation.

Thanks, 

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


Re: Not so simple date format question...

2010-04-28 Thread Jerry Barnes

You could also convert the date to a new format in a view.


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