So I don't need to lock application-scope variables? One book I have says I
should. How about request-scope vars?

~~~~~~~~~~~~~~~~~~~~~~~~
Ricq Pattay <[EMAIL PROTECTED]>
Univ of Minnesota - Twin Cities
College of Veterinary Medicine



----- Original Message -----
From: Todd Ashworth <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, August 29, 2000 3:49 PM
Subject: Re: CFLOCK datasource var?


> You shouldn't need to use a Session variable for your DSN .. especially if
> you are going to be setting it over and over in your Application.cfm.
That
> defeats the purpose of having a Session variable anyway.  You could get by
> with another scope .. say Variables.ds, or something.  That way, you
> wouldn't have to worry about locking at all.
>
> <cfif not IsDefined('Variables.ds')>
>     <cfset Variables.ds = "something_dev">
> </cfif>
>
> Todd Ashworth
>
> ----- Original Message -----
> From: "Ricq Pattay" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, August 29, 2000 4:42 PM
> Subject: CFLOCK datasource var?
>
>
> | In my application.cfm I set a session var for all my queries' datasource
> | like this:
> |
> | <cflock scope="session" timeout="30" type="exclusive">
> |  <cfset session.ds = "something_dev">
> | </cflock>
> |
> | So... Do I need to read-only lock every reference to session.ds in all
my
> | other templates where I have a query using that datasource session var?
> | e.g.,
> |
> | <cfquery name="get_year" datasource=#session.ds#>
> | select sysdate from dual
> | </cfquery>
> |
> | Since session.ds is always identical for every user of this site, what
> does
> | it matter if it's locked or not?
> |
> | ~~~~~~~~~~~~~~~~~~~~~~~~
> | Ricq Pattay <[EMAIL PROTECTED]>
> | Univ of Minnesota - Twin Cities
> | College of Veterinary Medicine
> |
> |
> |
> |
>
| --------------------------------------------------------------------------
> ----
> | Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
> | To Unsubscribe visit
> http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
> send a message to [EMAIL PROTECTED] with 'unsubscribe' in
> the body.
> |
>
>
> --------------------------------------------------------------------------
----
> Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
> To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
>

------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to