Oh, you can't access the servicefactory from a shared host? I guess
that makes sense, there's a lot of stuff in there that would affect all
customers on the box.
> -Original Message-
> From: Russ Michaels [mailto:[EMAIL PROTECTED]
> Sent: Monday, April 24, 2006 3:53 PM
>
> handy yes, i
handy yes, its just a shame its another thing to add to the list of things
that make CF unsuitable for shared hosting.
Russ
-Original Message-
From: "Munson, Jacob" <[EMAIL PROTECTED]>
To: CF-Talk
Date: Mon, 24 Apr 2006 14:50:49 -0600
Subject: RE: Why is there query.reco
Oh, sweet! That is a better way to do it. I guess as long as
servicefactory doesn't go away, this should work with furture versions.
I'd hate to see Adobe drop that, because I know a lot of people use it.
> -Original Message-
> From: Denny Valliant [mailto:[EMAIL PROTECTED]
> Sent: Frid
It might b e worth noting that you can use undocumented "don't use these
and expect them to work over time" type functions to use an existing
datasource, so you don't need to save your db user & pass "hard"ly.
Something like:
daFactory = CreateObject ("Java","
coldfusion.server.Servic
Jacob,
I am glad that you found it useful and managed to translate it for SQL
server as well. I also saw you blog post about this technique.
Thanks
Qasim
On 4/20/06, Munson, Jacob <[EMAIL PROTECTED]> wrote:
>
> I got this working for MS SQL, here's the code:
>
>
> //connection url
> connURL =
I got this working for MS SQL, here's the code:
//connection url
connURL = "jdbc:macromedia:sqlserver://server:1433";
jclass = createobject('java','java.lang.Class');
jclass.forName('macromedia.jdbc.sqlserver.SQLServerDriver');
driverManager = CreateObject('java', 'java.sql.DriverManager');
//use
> AFAIK the result attribute doesn't return records affected from
> insert/delete/updates. Please correct me if I am wrong.
You are right, I just tried it and it says "recordcount: 0", and the
only other data returned is cached, executiontime, and sql code.
---
This transmission may
Sam,
AFAIK the result attribute doesn't return records affected from
insert/delete/updates. Please correct me if I am wrong.
Thanks
Qasim
On 4/20/06, Sam Farmer <[EMAIL PROTECTED]> wrote:
>
> On 4/18/06, Mike Klostermeyer <[EMAIL PROTECTED]> wrote:
> > I wouldn't say that. Sometimes it is hel
On 4/18/06, Mike Klostermeyer <[EMAIL PROTECTED]> wrote:
> I wouldn't say that. Sometimes it is helpful to know how many records were
> updated or deleted without having to do a select query beforehand. Is there
> a Java service factory way of getting at this information?
>
CF7 has a result attr
Jacob,
Here is an example implementation for Oracle. You can definitely modify it
for any other database.
//connection url
connURL = "jdbc:macromedia:oracle://..";
jclass = createobject('java','java.lang.Class');
jclass.forName('macromedia.jdbc.oracle.OracleDriver');
driverManager = Cre
How do you do that?
> -Original Message-
> From: Qasim Rasheed [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, April 19, 2006 6:40 PM
>
> Well I have been using JDBC Statement call from CF and it
> will return you
> number of records effected for updated, inserts or deletes.
---
>>Well I have been using JDBC Statement call from CF and it will return you
number of records effected for updated, inserts or deletes.
Really? Then CF has no excuse anymore.
--
___
REUSE CODE! Use custom tags;
See http://www.contentbox.com/claude/customtags/
Well I have been using JDBC Statement call from CF and it will return you
number of records effected for updated, inserts or deletes.
Thanks
Qasim
On 4/19/06, Claude Schneegans <[EMAIL PROTECTED]> wrote:
>
> Not sure on which kind of database it will work.
> All I know is that it wont work with
Not sure on which kind of database it will work.
All I know is that it wont work with Access database.
Another way to get the same result would be to store a date time value
in the same query
as the INSERT or UPDATE, then count them in another query.
If the field is indexed, it should take a bree
This would work, as long as you're using MS SQL.
> -Original Message-
> From: Ben Nadel [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, April 19, 2006 1:26 PM
>
> I suppose one solutions, while it is a bit more work would be to have
> osmething like:
>
>
> DECLARE @record_count INT;
>
>
I suppose one solutions, while it is a bit more work would be to have
osmething like:
DECLARE @record_count INT;
SET @record_count = ISNULL(
(
SELECT COUNT(*) AS record_count FROM [TABLE] WHERE < where clauses >
),
0
);
UPDATE. WHERE..
SELECT
@record_count AS RecordC
>>CF doesn't appear to treat update queries the
same as select queries
I think a good reason is that a SELECT SQL query returns a dataset, an
INSERT, UPDATE or DELETE
does not.
What we call a QUERY in CF is actually a dataset, the SELECT, UPDATE or
other is not a query,
it is an SQL statement.
>>CF shouldn't return a RecordCount on non-selecting queries.
Well, the best would be it returns a sensible value. If it cannot,
better return nothing, AND document it.
--
___
REUSE CODE! Use custom tags;
See http://www.contentbox.com/claude/customtags/tagst
> it might be worth looking at whats returned in the
> metadata (getMetaData) and the query result structure
I did some testing, and CF doesn't appear to treat update queries the
same as select queries. Neither cfdump nor getMetaData work with an
update query, in fact CF doesn't even recognize th
ailto:[EMAIL PROTECTED]
Sent: Wednesday, April 19, 2006 2:13 PM
To: CF-Talk
Subject: Re: Why is there query.recordcount with non-SELECT queries?
>>are ya'll just debating usefullness? Or is the return of the recordcount
actually creating a problem somewhere?
I think the first two
That was my concensus early on. Seems like it would be a hard sell to
argue against either of those statements.
--
Rob Wilkerson
~|
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:238174
Archives: http://www.houseoffus
>>are ya'll just debating usefullness? Or is the return of the recordcount
actually creating a problem somewhere?
I think the first two messages in the thread are quite clear:
1. It would be useful that a query returns the number of updated record
in an UPDATE in query.recordCount
2. The qurery
day, April 19, 2006 1:51 PM
> To: CF-Talk
> Subject: Re: Why is there query.recordcount with non-SELECT queries?
>
> On 4/19/06, Jochem van Dieten <[EMAIL PROTECTED]> wrote:
>
>> Russ Michaels wrote:
>>
>>> No, only selects return a recordco
ailto:[EMAIL PROTECTED]
Sent: Wednesday, April 19, 2006 1:51 PM
To: CF-Talk
Subject: Re: Why is there query.recordcount with non-SELECT queries?
On 4/19/06, Jochem van Dieten <[EMAIL PROTECTED]> wrote:
> Russ Michaels wrote:
> >
> > No, only selects return a recordcount.
>
Dave Carabetta wrote:
> On 4/19/06, Jochem van Dieten <[EMAIL PROTECTED]> wrote:
>>
>> Maybe some implementations update the diagnostic area with that
>> information, but returning a count of the number of records
>> affected is not part of the SQL specification. More importantly,
>> it is only par
On 4/19/06, Jochem van Dieten <[EMAIL PROTECTED]> wrote:
> Russ Michaels wrote:
> >
> > No, only selects return a recordcount.
> > Although SQL does return a message about how many records are updated
>
> Maybe some implementations update the diagnostic area with that
> information, but returning a
Russ Michaels wrote:
>
> No, only selects return a recordcount.
> Although SQL does return a message about how many records are updated
Maybe some implementations update the diagnostic area with that
information, but returning a count of the number of records
affected is not part of the SQL spe
s is stored in the query object, so try cfdumping it
> and see if its there.
>
> Russ
>
> -Original Message-
> From: "Nashir Sunderji" <[EMAIL PROTECTED]>
> To: CF-Talk
> Date: Wed, 19 Apr 2006 08:25:58 +0100
> Subject: RE: Why is there query.re
-Original Message-
From: "Nashir Sunderji" <[EMAIL PROTECTED]>
To: CF-Talk
Date: Wed, 19 Apr 2006 08:25:58 +0100
Subject: RE: Why is there query.recordcount with non-SELECT queries?
> You log ingo to 'search' and type in search by name the letters
> naf and
You log ingo to 'search' and type in search by name the letters naf and
you should be able to find him
Customer service
-Original Message-
From: Pete Ruckelshaus [mailto:[EMAIL PROTECTED]
Sent: 18 April 2006 16:16
To: CF-Talk
Subject: Why is there query.recordcount with non-SELECT q
14
212.691.3477 fax
www.nylontechnology.com
Sanders: Lightspeed too slow?
Helmet: Yes we'll have to go right to ludacris speed.
-Original Message-
From: Ryan Guill [mailto:[EMAIL PROTECTED]
Sent: Tuesday, April 18, 2006 1:02 PM
To: CF-Talk
Subject: Re: Why is there query.recordcount
; information?
> >
> > Mike
> >
> > -----Original Message-----
> > From: Rob Wilkerson [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, April 18, 2006 10:22 AM
> > To: CF-Talk
> > Subject: Re: Why is there query.recordcount with non-SELECT queries?
> &
o ludacris speed.
-Original Message-
From: Rob Wilkerson [mailto:[EMAIL PROTECTED]
Sent: Tuesday, April 18, 2006 11:32 AM
To: CF-Talk
Subject: Re: Why is there query.recordcount with non-SELECT queries?
Sorry, I should have been more clear. I meant that the return value
(queryname.recordCoun
r deleted without having to do a select query beforehand. Is there
> a Java service factory way of getting at this information?
>
> Mike
>
> -Original Message-
> From: Rob Wilkerson [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, April 18, 2006 10:22 AM
> To: CF-Talk
>
Sent: Tuesday, April 18, 2006 10:22 AM
To: CF-Talk
Subject: Re: Why is there query.recordcount with non-SELECT queries?
As I recall, the value gets returned, but always says "0". It's not
useful for anything other than select queries.
On 4/18/06, Pete Ruckelshaus <[EMAIL PROT
As I recall, the value gets returned, but always says "0". It's not
useful for anything other than select queries.
On 4/18/06, Pete Ruckelshaus <[EMAIL PROTECTED]> wrote:
> Should queries that do an update return a queryname.recordcount
> variable? I'm trying to determine how many records get ch
36 matches
Mail list logo