Query not parsed?

6 views
Skip to first unread message

Moni

unread,
Sep 1, 2010, 1:29:11 PM9/1/10
to transfer-dev
Hi,

I'm using Transfer 1.1 with Oracle 10 Database on Coldfusion MX 7 with
the Hotfix 2.

I'm trying to receive a resultset with transfer.get() on two different
server.
On the first server I get the correct resultset but the second server
throws an sql-error. It says "ORA-01722: invalid Number".
It seems that the query wasn't parsed, it still contains (param 1),
(param 2) and so on (see below).

The configurations (CF and Database) on both servers are indentical
except the OS. The first machine runs with Window Server 2000, the
other with Windows XP.

Does anyone have any suggestions?

Here is the transfer.xml

<transfer>
<objectDefinitions>
<object name="mandant" table="besuv.mandant">
<id name="mid" type="numeric" />
<property name="mandant_sts" type="numeric" column="sts"/>
<property name="mandant" type="string" />
</object>
<object name="besucher" table="besuv.besucher">
<compositeid>
<manytoone name="mid" />
<property name="bid" />
</compositeid>
<manytoone name="mid">
<link column="mid" to="mandant"/>
</manytoone>
<property name="bid" type="numeric" />
<property name="sts" type="numeric" />
<property name="nname" type="string" />
<property name="vname" type="string" />
</object>
</objectDefinitions>
</transfer>

And this is the CF-Code:

<cfset key = StructNew()>
<cfset tmp = StructInsert( key, "mid", 1)>
<cfset tmp = StructInsert( key, "bid", 1000)>

<cfset oBesucher = application.transfer.get( "besucher", key )>


SQL-Query from the SQL-Error:
SELECT NULL AS mandant,
besuv_besucher_1.mid,
besuv_besucher_1.vname,
besuv_besucher_1.nname,
besuv_besucher_1.sts,
besuv_besucher_1.bid,
besuv_besucher_1.bid
||'|'
||besuv_besucher_1.mid
||'|' AS transfer_compositeid,
NULL AS transfer_parentKey,
1 AS transfer_orderIndex,
'besucher' AS transfer_className,
'' AS transfer_parentClassName,
'' AS transfer_parentParentClassName,
'' AS transfer_parentCompositeName,
'false' AS transfer_isArray,
'' AS transfer_compositeName,
'false' AS transfer_isProxied
FROM besuv.besucher besuv_besucher_1
WHERE besuv_besucher_1.bid = (param 1)
AND besuv_besucher_1.mid = (param 2)
UNION ALL
SELECT besuv_mandant_2.mandant,
besuv_mandant_2.mid,
NULL AS vname,
NULL AS nname,
besuv_mandant_2.sts,
NULL AS bid,
'' AS transfer_compositeid,
CAST(besuv_besucher_1.bid
||'|'
||besuv_besucher_1.mid
||'|' AS VARCHAR2(1000)) AS transfer_parentKey,
2 AS transfer_orderIndex,
'mandant' AS transfer_className,
'besucher' AS transfer_parentClassName,
'' AS transfer_parentParentClassName,
'' AS transfer_parentCompositeName,
'false' AS transfer_isArray,
'mid' AS transfer_compositeName,
'false' AS transfer_isProxied
FROM besuv.besucher besuv_besucher_1
INNER JOIN besuv.mandant besuv_mandant_2
ON besuv_besucher_1.mid = besuv_mandant_2.mid
WHERE besuv_besucher_1.bid = (param 3)
AND besuv_besucher_1.mid = (param 4)
AND besuv_mandant_2.mid IS NOT NULL
ORDER BY transfer_orderIndex ASC

Mark Mandel

unread,
Sep 2, 2010, 3:29:55 AM9/2/10
to transf...@googlegroups.com
What are the param values?

Looks like you're passing a string to something that is expecting a number.

http://ora-01722.ora-code.com/

Mark

--
Before posting questions to the group please read:
http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer

Try out the new Transfer ORM Custom Google Search:
http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8

You received this message because you are subscribed to the Google Groups "transfer-dev" group.
To post to this group, send email to transf...@googlegroups.com
To unsubscribe from this group, send email to transfer-dev...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en



--
E: mark....@gmail.com
T: http://www.twitter.com/neurotic
W: www.compoundtheory.com

cf.Objective(ANZ) - Nov 18, 19 - Melbourne Australia
http://www.cfobjective.com.au

Hands-on ColdFusion ORM Training
www.ColdFusionOrmTraining.com

Moni

unread,
Sep 2, 2010, 3:53:54 AM9/2/10
to transfer-dev
Hi Mark,

Thanks for your reply.

I send this structure to transfer.get():

<cfset key = StructNew()>
<cfset tmp = StructInsert( key, "mid", 1)>
<cfset tmp = StructInsert( key, "bid", 1000)>

<cfset oBesucher = application.transfer.get( "besucher", key )>

And it works fine but not on the "second server" (see my first post).

Anymore hints?

Greeting, Moni
> >http://groups.google.com/group/transfer-dev/web/how-to-ask-support-qu...
>
> > Try out the new Transfer ORM Custom Google Search:
> >http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8
>
> > You received this message because you are subscribed to the Google Groups
> > "transfer-dev" group.
> > To post to this group, send email to transf...@googlegroups.com
> > To unsubscribe from this group, send email to
> > transfer-dev...@googlegroups.com<transfer-dev%2Bunsu...@googlegroups.com>
> > For more options, visit this group at
> >http://groups.google.com/group/transfer-dev?hl=en
>
> --
> E: mark.man...@gmail.com

Mark Mandel

unread,
Sep 3, 2010, 7:14:40 PM9/3/10
to transf...@googlegroups.com
I meant - what are the query param values?

Do the values of the query params match up to what the columns data types are in the database?

Mark



Try out the new Transfer ORM Custom Google Search:
http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8

You received this message because you are subscribed to the Google Groups "transfer-dev" group.
To post to this group, send email to transf...@googlegroups.com
To unsubscribe from this group, send email to transfer-dev...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en



--
E: mark....@gmail.com

Moni

unread,
Sep 6, 2010, 6:09:43 AM9/6/10
to transfer-dev
Hi Mark,

the data types are correct (number).

As mentioned in the first post:
I run the same scripts with the same database on two different CF-
Servers. And only one throws this error. But both CF-servers have the
same configuration.

Greetings, Moni
> > <transfer-dev%2Bunsu...@googlegroups.com<transfer-dev%252Buns...@googlegroups.com>

Mark Mandel

unread,
Sep 6, 2010, 7:02:17 AM9/6/10
to transf...@googlegroups.com
One of the data types can't be correct, otherwise Oracle wouldn't be throwing an exception ;o)

So what are they on the system that fails?

Mark



Try out the new Transfer ORM Custom Google Search:
http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8

You received this message because you are subscribed to the Google Groups "transfer-dev" group.
To post to this group, send email to transf...@googlegroups.com
To unsubscribe from this group, send email to transfer-dev...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en



--
E: mark....@gmail.com

Moni

unread,
Sep 7, 2010, 6:45:24 AM9/7/10
to transfer-dev
Hi Mark,

I wish it would be so easy *sigh*. ;o)

The database is the same. It's the same datasource, set in the CF-
Administor on both server. The db is running on a seperate server.

Here is the error message, maybe it could help.
http://www.rebsdat.de/transfer/error_result.htm (it's only a copy!)

I do believe it's a stupid error, but i can't find it :(

Greetings, Moni
> > > > <transfer-dev%2Bunsu...@googlegroups.com<transfer-dev%252Buns...@googlegroups.com>
> > <transfer-dev%252Buns...@googlegroups.com<transfer-dev%25252Bun...@googlegroups.com>

Mark Mandel

unread,
Sep 7, 2010, 7:34:56 AM9/7/10
to transf...@googlegroups.com
Yup.. that IS a weird one.

It's the cfquery that is failing... so uhmn.. CFML bug?

Check the CF version numbers on each server, see if they match. Maybe there is a hotfix on one that isn't on the other.

Mark



Try out the new Transfer ORM Custom Google Search:
http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8

You received this message because you are subscribed to the Google Groups "transfer-dev" group.
To post to this group, send email to transf...@googlegroups.com
To unsubscribe from this group, send email to transfer-dev...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en



--
E: mark....@gmail.com

Moni

unread,
Sep 7, 2010, 10:09:13 AM9/7/10
to transfer-dev
Hi Mark,

now it works.

That was a funny thing (not HA!-HA!-Funny ;o) ): It's the same
Version: ColdFusion Server Enterprise 7,0,2,142559 with the same
update level.
But I compared all .jar in the lib-Folder and the
macromedia_drivers.jar was different. I replaced it with the file from
the "well-behaved" server and now everthing is working fine.

Thanks for your help and your patiences.

Greetings, Moni


On 7 Sep., 13:34, Mark Mandel <mark.man...@gmail.com> wrote:
> Yup.. that IS a weird one.
>
> It's the cfquery that is failing... so uhmn.. CFML bug?
>
> Check the CF version numbers on each server, see if they match. Maybe there
> is a hotfix on one that isn't on the other.
>
> Mark
>
> On Tue, Sep 7, 2010 at 8:45 PM, Moni <rebs...@media-solutions.de> wrote:
> > Hi Mark,
>
> > I wish it would be so easy *sigh*. ;o)
>
> > The database is the same. It's the same datasource, set in the CF-
> > Administor on both server. The db is running on a seperate server.
>
> > Here is the error message, maybe it could help.
> >http://www.rebsdat.de/transfer/error_result.htm(it's only a copy!)
> > > > > > <transfer-dev%2Bunsu...@googlegroups.com<transfer-dev%252Buns...@googlegroups.com>
> > <transfer-dev%252Buns...@googlegroups.com<transfer-dev%25252Bun...@googlegroups.com>
>
> > > > <transfer-dev%252Buns...@googlegroups.com<transfer-dev%25252Bun...@googlegroups.com>
> > <transfer-dev%25252Bun...@googlegroups.com<transfer-dev%2525252Bu...@googlegroups.com>
>
> > > > > > > > For more options, visit this group at
> > > > > > > >http://groups.google.com/group/transfer-dev?hl=en
>
> > > > > > > --
> > > > > > > E: mark.man...@gmail.com
> > > > > > > T:http://www.twitter.com/neurotic
> > > > > > > W:www.compoundtheory.com
>
> > > > > > > cf.Objective(ANZ) - Nov 18, 19 - Melbourne Australiahttp://
> > > > > >www.cfobjective.com.au
>
> > > > > > > Hands-on ColdFusion ORM Trainingwww.ColdFusionOrmTraining.com
>
> > > > > > --
> > > > > > Before posting questions to the group please read:
>
> >http://groups.google.com/group/transfer-dev/web/how-to-ask-support-qu.
> > > > ..
>
> > > > > > Try out the new Transfer ORM Custom Google Search:
> > > > > >http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8
>
> > > > > > You received this message because you are subscribed to the Google
> > > > Groups
> > > > > > "transfer-dev" group.
> > > > > > To post to this group, send email to transf...@googlegroups.com
> > > > > > To unsubscribe from this group, send email to
> > > > > > transfer-dev...@googlegroups.com<transfer-dev%2Bunsu...@googlegroups.com>
>
> ...
>
> Erfahren Sie mehr »
Reply all
Reply to author
Forward
0 new messages