Re: DataSource Events like Before Commit?
Yes, I'll work on something like that but it requires heavy testing to make sure that the solution is correct. Pooling is quite a difficult topic and not very much documented topic (I could not find a document that explains how the ColdFusion driver is communicating with Oracle - like what if the pool size is set to 1 and there are two concurrent connections, then what happens with the Oracle session - does it open a session for each user or it uses time-sharing, etc.?). It could be the case that when I set the user id through a stored procedure, another user comes in, reusing an existing connection from the pool, and then that will mess up the authentication process. However, through transactions we are guaranteed that what is in the transaction is committed/rollbacked in a block. The disadvantage with transactions is that they cannot be nested and they affect the performance. >Why not just set it in their session and then you are only setting it once >and referencing that for each query you execute. ~| 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:309472 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: DataSource Events like Before Commit?
Why not just set it in their session and then you are only setting it once and referencing that for each query you execute. On Tue, Jul 22, 2008 at 9:06 AM, Joseph Bugeja <[EMAIL PROTECTED]> wrote: > Dave, > > That's exactly what I was looking for - proxy authentication. I created a > thread on this forum about this but the reply I got is that ColdFusion does > not natively support this. So, the solution is to either create our own JNDI > datasource using Java. However, I decided to not go this way and instead set > the client identifier prior to executing each query. This should work and > according to my testing it does not inflict a heavy performance degradation. > > >Joseph, > > > >I did some googling and found that Oracle has 'proxy user authentication'. > >See this Ask Tom article (someone wanting to do the same thing as you are, > >but in java): > > > >http://tinyurl.com/6qe8xk > > > >Although I don't know if you can do it with the ColdFusion setup directly, > >but maybe you can access some underlying java component to do it. > Hopefully > >this might give you another alternative. Let me know how it turns out. > > > >Dave > > > ~| 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:309458 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: DataSource Events like Before Commit?
Dave, That's exactly what I was looking for - proxy authentication. I created a thread on this forum about this but the reply I got is that ColdFusion does not natively support this. So, the solution is to either create our own JNDI datasource using Java. However, I decided to not go this way and instead set the client identifier prior to executing each query. This should work and according to my testing it does not inflict a heavy performance degradation. >Joseph, > >I did some googling and found that Oracle has 'proxy user authentication'. >See this Ask Tom article (someone wanting to do the same thing as you are, >but in java): > >http://tinyurl.com/6qe8xk > >Although I don't know if you can do it with the ColdFusion setup directly, >but maybe you can access some underlying java component to do it. Hopefully >this might give you another alternative. Let me know how it turns out. > >Dave > >Exactly! > >You perfectly understood my concern. If ColdFusion supported dynamic >connection parameter injection or proxy authentication then we can identify >the connection pool users but there is no straightforward solution to this. >Through pooling we are connected through one db user which for security >complaince (PCI) we need to remove this hole while keeping the benefits of >pooling. Triggers can help certainly help us for auditing but again at db >level I do not want have the same user showing up in my logs. > >>Got it. Now I understand better. You want to pass the userid of your >>'logged in user' to track the change in the database instead of using the >>user id that the datasource is logged in as. >> >>I don't see any way for you to do this without changing your code. Maybe >>someone else can come up with something, but I just don't see any way >around >>it. Whether you change it to implement the idea you had below or do it >some >>other way, bottom line is, you will need to change your code to make Oracle >>aware of each individual user's ID. >> >>You might still be able to find a way to use the triggers, but I still >think >alternative. ~| 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:309457 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: DataSource Events like Before Commit?
Joseph, I did some googling and found that Oracle has 'proxy user authentication'. See this Ask Tom article (someone wanting to do the same thing as you are, but in java): http://tinyurl.com/6qe8xk Although I don't know if you can do it with the ColdFusion setup directly, but maybe you can access some underlying java component to do it. Hopefully this might give you another alternative. Let me know how it turns out. Dave -Original Message- From: Joseph Bugeja [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 22, 2008 7:57 AM To: CF-Talk Subject: Re: DataSource Events like Before Commit? Exactly! You perfectly understood my concern. If ColdFusion supported dynamic connection parameter injection or proxy authentication then we can identify the connection pool users but there is no straightforward solution to this. Through pooling we are connected through one db user which for security complaince (PCI) we need to remove this hole while keeping the benefits of pooling. Triggers can help certainly help us for auditing but again at db level I do not want have the same user showing up in my logs. >Got it. Now I understand better. You want to pass the userid of your >'logged in user' to track the change in the database instead of using the >user id that the datasource is logged in as. > >I don't see any way for you to do this without changing your code. Maybe >someone else can come up with something, but I just don't see any way around >it. Whether you change it to implement the idea you had below or do it some >other way, bottom line is, you will need to change your code to make Oracle >aware of each individual user's ID. > >You might still be able to find a way to use the triggers, but I still think >you'll need a code change. > >Sorry, no help. > >Dave >Thanks again for your reply. > >Unfortunately, I need to pass the userid prior to executing each query as >otherwise the auditing function would not know the userid. We have triggers >on tables but triggers need the read the userid apriori. > >ColdFusion does not allow us to build our connection string dynamically or >to dynamically inject connection string variables (such as the userid), as >is the case with VB.NET and C#. This is why I am looking for an alternative. > >>Joseph, >> >>I think Gert's suggestion earlier could work for you. You could design a >>trigger to fire the stored procedure prior to any Inserts or Updates. >Check >a >before ~| 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:309453 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: DataSource Events like Before Commit?
Exactly! You perfectly understood my concern. If ColdFusion supported dynamic connection parameter injection or proxy authentication then we can identify the connection pool users but there is no straightforward solution to this. Through pooling we are connected through one db user which for security complaince (PCI) we need to remove this hole while keeping the benefits of pooling. Triggers can help certainly help us for auditing but again at db level I do not want have the same user showing up in my logs. >Got it. Now I understand better. You want to pass the userid of your >'logged in user' to track the change in the database instead of using the >user id that the datasource is logged in as. > >I don't see any way for you to do this without changing your code. Maybe >someone else can come up with something, but I just don't see any way around >it. Whether you change it to implement the idea you had below or do it some >other way, bottom line is, you will need to change your code to make Oracle >aware of each individual user's ID. > >You might still be able to find a way to use the triggers, but I still think >you'll need a code change. > >Sorry, no help. > >Dave >Thanks again for your reply. > >Unfortunately, I need to pass the userid prior to executing each query as >otherwise the auditing function would not know the userid. We have triggers >on tables but triggers need the read the userid apriori. > >ColdFusion does not allow us to build our connection string dynamically or >to dynamically inject connection string variables (such as the userid), as >is the case with VB.NET and C#. This is why I am looking for an alternative. > >>Joseph, >> >>I think Gert's suggestion earlier could work for you. You could design a >>trigger to fire the stored procedure prior to any Inserts or Updates. >Check >a >before ~| 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:309448 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
RE: DataSource Events like Before Commit?
Got it. Now I understand better. You want to pass the userid of your 'logged in user' to track the change in the database instead of using the user id that the datasource is logged in as. I don't see any way for you to do this without changing your code. Maybe someone else can come up with something, but I just don't see any way around it. Whether you change it to implement the idea you had below or do it some other way, bottom line is, you will need to change your code to make Oracle aware of each individual user's ID. You might still be able to find a way to use the triggers, but I still think you'll need a code change. Sorry, no help. Dave -Original Message- From: Joseph Bugeja [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 22, 2008 7:28 AM To: CF-Talk Subject: Re: DataSource Events like Before Commit? Thanks again for your reply. Unfortunately, I need to pass the userid prior to executing each query as otherwise the auditing function would not know the userid. We have triggers on tables but triggers need the read the userid apriori. ColdFusion does not allow us to build our connection string dynamically or to dynamically inject connection string variables (such as the userid), as is the case with VB.NET and C#. This is why I am looking for an alternative. >Joseph, > >I think Gert's suggestion earlier could work for you. You could design a >trigger to fire the stored procedure prior to any Inserts or Updates. Check >out this page on oracle site for some direction: > >http://tinyurl.com/5sjhlg > >I haven't done anything with triggers myself. But if you want to avoid >re-coding your CFML, I think this is your route to go. > >Of course, this will only work for you if the only thing changing your >tables is your CF app. Any manual changes to the database, or any other >application accessing the same database would fire the triggers as well, >unless you can figure out a way to make them fire only when your app >accesses the database. > >Hope this helps, > >Dave Phillips > >Thanks for your reply. Let me explain our scenario. > >We have a number of cfquery tags that insert, update and delete data from >our Oracle database. Basically, before each query is run I need to execute a >stored procedure. This stored procedure sets the userid (the user currently >logged in) in the database for auditing purposes. We have hundreds of >queries and it is not good from a design perspective to rewrite each query >to call the same central piece of code before each query gets executed. > >So my original query should be: > Original Query: > > DML Operation > > >New requirement should be: > > > Set the user id > > > DML Operation > > > >As shown above, I need to call the cfstoredproc before each query is >executed. Personally, I would prefer if I keep my original design and before >the original query is run the ColdFusion engine automatically injects the >new call in a transaction to set the clientid. > >Do you have any suggestions? > >before >>ColdFusion executes the code found in the cfquery I would like it to >>automatically execute another query for example to set the user id to the >>database? In this way I do not need to make any modification to the >existing >>code except that of creating new code to do something before executing my >>main query? >> >>Thanks in advance for your assistance. >> >>Regards, >>Joseph. ~| 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:309445 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: DataSource Events like Before Commit?
Thanks again for your reply. Unfortunately, I need to pass the userid prior to executing each query as otherwise the auditing function would not know the userid. We have triggers on tables but triggers need the read the userid apriori. ColdFusion does not allow us to build our connection string dynamically or to dynamically inject connection string variables (such as the userid), as is the case with VB.NET and C#. This is why I am looking for an alternative. >Joseph, > >I think Gert's suggestion earlier could work for you. You could design a >trigger to fire the stored procedure prior to any Inserts or Updates. Check >out this page on oracle site for some direction: > >http://tinyurl.com/5sjhlg > >I haven't done anything with triggers myself. But if you want to avoid >re-coding your CFML, I think this is your route to go. > >Of course, this will only work for you if the only thing changing your >tables is your CF app. Any manual changes to the database, or any other >application accessing the same database would fire the triggers as well, >unless you can figure out a way to make them fire only when your app >accesses the database. > >Hope this helps, > >Dave Phillips > >Thanks for your reply. Let me explain our scenario. > >We have a number of cfquery tags that insert, update and delete data from >our Oracle database. Basically, before each query is run I need to execute a >stored procedure. This stored procedure sets the userid (the user currently >logged in) in the database for auditing purposes. We have hundreds of >queries and it is not good from a design perspective to rewrite each query >to call the same central piece of code before each query gets executed. > >So my original query should be: > Original Query: > > DML Operation > > >New requirement should be: > > > Set the user id > > > DML Operation > > > >As shown above, I need to call the cfstoredproc before each query is >executed. Personally, I would prefer if I keep my original design and before >the original query is run the ColdFusion engine automatically injects the >new call in a transaction to set the clientid. > >Do you have any suggestions? > >before >>ColdFusion executes the code found in the cfquery I would like it to >>automatically execute another query for example to set the user id to the >>database? In this way I do not need to make any modification to the >existing >>code except that of creating new code to do something before executing my >>main query? >> >>Thanks in advance for your assistance. >> >>Regards, >>Joseph. ~| 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:309442 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: DataSource Events like Before Commit?
You could make them fire based upon a null value or value not being set at all. For example if UserID is in fact passed in then do not fire trigger but if UserID is not passed in then fire the trigger. I think that would then work fine for the CF pages interacting with things and then when manually interacting so long as the person doing the queries remembers the triggers are in place then they could bypass them that way. Although if someone knew they were in place they could also just disable the trigger, run whatever they needed to do and then re-enable the trigger. On Tue, Jul 22, 2008 at 7:20 AM, Experienced CF Developer < [EMAIL PROTECTED]> wrote: > Joseph, > > I think Gert's suggestion earlier could work for you. You could design a > trigger to fire the stored procedure prior to any Inserts or Updates. > Check > out this page on oracle site for some direction: > > http://tinyurl.com/5sjhlg > > I haven't done anything with triggers myself. But if you want to avoid > re-coding your CFML, I think this is your route to go. > > Of course, this will only work for you if the only thing changing your > tables is your CF app. Any manual changes to the database, or any other > application accessing the same database would fire the triggers as well, > unless you can figure out a way to make them fire only when your app > accesses the database. > > Hope this helps, > > Dave Phillips > > -Original Message- > From: Joseph Bugeja [mailto:[EMAIL PROTECTED] > Sent: Tuesday, July 22, 2008 6:51 AM > To: CF-Talk > Subject: Re: DataSource Events like Before Commit? > > Thanks for your reply. Let me explain our scenario. > > We have a number of cfquery tags that insert, update and delete data from > our Oracle database. Basically, before each query is run I need to execute > a > stored procedure. This stored procedure sets the userid (the user currently > logged in) in the database for auditing purposes. We have hundreds of > queries and it is not good from a design perspective to rewrite each query > to call the same central piece of code before each query gets executed. > > So my original query should be: > Original Query: > > DML Operation > > > New requirement should be: > > >Set the user id > > >DML Operation > > > > As shown above, I need to call the cfstoredproc before each query is > executed. Personally, I would prefer if I keep my original design and > before > the original query is run the ColdFusion engine automatically injects the > new call in a transaction to set the clientid. > > Do you have any suggestions? > > >Joseph, > > > >I don't think what you are trying to do is possible. Can you give us some > >more details of what you are trying to accomplish to see if we can help > you > >come up with an alternative solution? > > > >Sincerely, > > > >Dave Phillips > > > >Dear ColdFusion Users, > > > >Is there a way that I can attach to a datasource through an event like > >before_commit or before_update? > > > >So, if I have a cfquery tag, and I would ColdFusion to automatically, > before > >ColdFusion executes the code found in the cfquery I would like it to > >automatically execute another query for example to set the user id to the > >database? In this way I do not need to make any modification to the > existing > >code except that of creating new code to do something before executing my > >main query? > > > >Thanks in advance for your assistance. > > > >Regards, > >Joseph. > > > > ~| 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:309441 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
RE: DataSource Events like Before Commit?
Joseph, I think Gert's suggestion earlier could work for you. You could design a trigger to fire the stored procedure prior to any Inserts or Updates. Check out this page on oracle site for some direction: http://tinyurl.com/5sjhlg I haven't done anything with triggers myself. But if you want to avoid re-coding your CFML, I think this is your route to go. Of course, this will only work for you if the only thing changing your tables is your CF app. Any manual changes to the database, or any other application accessing the same database would fire the triggers as well, unless you can figure out a way to make them fire only when your app accesses the database. Hope this helps, Dave Phillips -Original Message- From: Joseph Bugeja [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 22, 2008 6:51 AM To: CF-Talk Subject: Re: DataSource Events like Before Commit? Thanks for your reply. Let me explain our scenario. We have a number of cfquery tags that insert, update and delete data from our Oracle database. Basically, before each query is run I need to execute a stored procedure. This stored procedure sets the userid (the user currently logged in) in the database for auditing purposes. We have hundreds of queries and it is not good from a design perspective to rewrite each query to call the same central piece of code before each query gets executed. So my original query should be: Original Query: DML Operation New requirement should be: Set the user id DML Operation As shown above, I need to call the cfstoredproc before each query is executed. Personally, I would prefer if I keep my original design and before the original query is run the ColdFusion engine automatically injects the new call in a transaction to set the clientid. Do you have any suggestions? >Joseph, > >I don't think what you are trying to do is possible. Can you give us some >more details of what you are trying to accomplish to see if we can help you >come up with an alternative solution? > >Sincerely, > >Dave Phillips > >Dear ColdFusion Users, > >Is there a way that I can attach to a datasource through an event like >before_commit or before_update? > >So, if I have a cfquery tag, and I would ColdFusion to automatically, before >ColdFusion executes the code found in the cfquery I would like it to >automatically execute another query for example to set the user id to the >database? In this way I do not need to make any modification to the existing >code except that of creating new code to do something before executing my >main query? > >Thanks in advance for your assistance. > >Regards, >Joseph. ~| 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:309439 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Re: DataSource Events like Before Commit?
Are you using components for all your data access transactions (ie. dao, etc)? If so, and you are using ColdSpring (or some other bean factory) to manage your cfcs, this would be a perfect place for AOP. If you are not using a bean factory, you could create a lightweight aop style function / component method that looks something like: FUNCTION doDBTransaction ARG1 - userId ARG2 - daoObject ARG3 - daoMethodToRun ARG4 - daoMethodArgs BEGIN TRANSACTION DO code to store current user in db SET returnval = daoObject.daoMethodToRun(daoMethodArgs) DO whatever cleanup code you may have END TRANSACTION RETURN returnVal If you are not using components for your db transactions you could possibly do something similar; perhaps passing in the name of templates that hold the queries. HTH Dominic -- Blog it up: http://fusion.dominicwatson.co.uk ~| 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:309436 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: DataSource Events like Before Commit?
Thanks for your reply. Let me explain our scenario. We have a number of cfquery tags that insert, update and delete data from our Oracle database. Basically, before each query is run I need to execute a stored procedure. This stored procedure sets the userid (the user currently logged in) in the database for auditing purposes. We have hundreds of queries and it is not good from a design perspective to rewrite each query to call the same central piece of code before each query gets executed. So my original query should be: Original Query: DML Operation New requirement should be: Set the user id DML Operation As shown above, I need to call the cfstoredproc before each query is executed. Personally, I would prefer if I keep my original design and before the original query is run the ColdFusion engine automatically injects the new call in a transaction to set the clientid. Do you have any suggestions? >Joseph, > >I don't think what you are trying to do is possible. Can you give us some >more details of what you are trying to accomplish to see if we can help you >come up with an alternative solution? > >Sincerely, > >Dave Phillips > >Dear ColdFusion Users, > >Is there a way that I can attach to a datasource through an event like >before_commit or before_update? > >So, if I have a cfquery tag, and I would ColdFusion to automatically, before >ColdFusion executes the code found in the cfquery I would like it to >automatically execute another query for example to set the user id to the >database? In this way I do not need to make any modification to the existing >code except that of creating new code to do something before executing my >main query? > >Thanks in advance for your assistance. > >Regards, >Joseph. ~| 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:309435 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Re: DataSource Events like Before Commit?
Well you can use database triggers on tables for this matter, if your queries are related to simple tables... 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 Joseph Bugeja schrieb: > Dear ColdFusion Users, > > Is there a way that I can attach to a datasource through an event like > before_commit or before_update? > > So, if I have a cfquery tag, and I would ColdFusion to automatically, before > ColdFusion executes the code found in the cfquery I would like it to > automatically execute another query for example to set the user id to the > database? In this way I do not need to make any modification to the existing > code except that of creating new code to do something before executing my > main query? > > Thanks in advance for your assistance. > > Regards, > Joseph. > > ~| 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:309433 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
RE: DataSource Events like Before Commit?
Joseph, I don't think what you are trying to do is possible. Can you give us some more details of what you are trying to accomplish to see if we can help you come up with an alternative solution? Sincerely, Dave Phillips -Original Message- From: Joseph Bugeja [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 22, 2008 4:50 AM To: CF-Talk Subject: DataSource Events like Before Commit? Dear ColdFusion Users, Is there a way that I can attach to a datasource through an event like before_commit or before_update? So, if I have a cfquery tag, and I would ColdFusion to automatically, before ColdFusion executes the code found in the cfquery I would like it to automatically execute another query for example to set the user id to the database? In this way I do not need to make any modification to the existing code except that of creating new code to do something before executing my main query? Thanks in advance for your assistance. Regards, Joseph. ~| 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:309432 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
DataSource Events like Before Commit?
Dear ColdFusion Users, Is there a way that I can attach to a datasource through an event like before_commit or before_update? So, if I have a cfquery tag, and I would ColdFusion to automatically, before ColdFusion executes the code found in the cfquery I would like it to automatically execute another query for example to set the user id to the database? In this way I do not need to make any modification to the existing code except that of creating new code to do something before executing my main query? Thanks in advance for your assistance. Regards, Joseph. ~| 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:309431 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4