• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Mysql and pk fetches with EOUtil or ERXEOControlUtil. Adaptor bug?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Mysql and pk fetches with EOUtil or ERXEOControlUtil. Adaptor bug?


  • Subject: Mysql and pk fetches with EOUtil or ERXEOControlUtil. Adaptor bug?
  • From: William Hatch <email@hidden>
  • Date: Thu, 18 Sep 2008 15:50:16 -0400

Just migrated a project to mysql, and now all methods that used the ERXEOControlUtilities.objectWithPrimaryKey() method no longer work and throw the following exception:

Sep 18 15:21:38 Analytics[55555] (ERXNSLogLog4jBridge.java:41) WARN NSLog - <com.codefab.analytics.DirectAction>: Exception in performActionNamed() on the action "pkFetchWithMySQLProblem" with the message: com.webobjects.jdbcadaptor.JDBCAdaptorException: The attribute id should be assigned a Number, but the value was the String "1000002"
java.lang.reflect.InvocationTargetException
[2008-09-18 15:21:38 EDT] <WorkerThread5> com.webobjects.jdbcadaptor.JDBCAdaptorException: The attribute id should be assigned a Number, but the value was the String "1000002"
at com.webobjects.jdbcadaptor.JDBCColumn.takeInputValue(JDBCColumn.java: 557)
at com .webobjects .jdbcadaptor .JDBCChannel ._bindInputVariablesWithBindingsAndExecute(JDBCChannel.java:226)
at com .webobjects .jdbcadaptor.JDBCChannel._evaluateExpression(JDBCChannel.java:303)
at com .webobjects .jdbcadaptor.JDBCChannel.evaluateExpression(JDBCChannel.java:261)
at com .webobjects.jdbcadaptor.JDBCChannel.selectAttributes(JDBCChannel.java: 185)


This was working in FB no problem. I was initially passing the string representing the decoded id from the request as the argument to the method. But, I've tried all the EOUtilitiesMethods, converting the pk string into a GID or converting it into an Integer, but I always get this value massaged into a string. Here's the current call:

EOUtilities.objectWithPrimaryKeyValue(ec, entityName, new Integer(pkValue)); where pkValue is a string, ec and entityName are pretty obvious hopefully;-)

What am I doing wrong? Could this be a bug?

Bill



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Mysql and pk fetches with EOUtil or ERXEOControlUtil. Adaptor bug?
      • From: Chuck Hill <email@hidden>
  • Prev by Date: Re: Question about search performance
  • Next by Date: Re: Mysql and pk fetches with EOUtil or ERXEOControlUtil. Adaptor bug?
  • Previous by thread: Re: faulty documentation?
  • Next by thread: Re: Mysql and pk fetches with EOUtil or ERXEOControlUtil. Adaptor bug?
  • Index(es):
    • Date
    • Thread