• 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
Re: JDBCAdaptor LIKE clause problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: JDBCAdaptor LIKE clause problem


  • Subject: Re: JDBCAdaptor LIKE clause problem
  • From: Ricardo Strausz <email@hidden>
  • Date: Mon, 18 Aug 2003 13:22:52 -0500

From the error (and the sql) showed it seems that the object send to the format is not beeing interpreted (parsed) correctly.
you may try to puth sigle coutes arround...
which wild-card are you using?


On sabado, agos 16, 2003, at 16:26 America/Mexico_City, Peter Fournier wrote:

Ever since I went from 4.5 to 5.2 I have not been able to perform LIKE
searches. At the end of this email you can see my filter going into
EOUtilities.objectsWithQualifierFormat, the SQL the launch window shows as
generated, and the error message I receive in the launch window.


Does anyone have a workaround for this? It appears that the MicroSoftPlugIn
is generating invalid SQL and needs to be replaced, but I have not been able
to locate source code for it.


I am running MS SQL Server 7 and WO 5.2 on Win2k. This all worked fine in
4.5.


Any help appreciated. Thanks,

Pete Fournier
email@hidden


FILTER PUT INTO EOUtilities.objectsWithQualifierFormat ALONG WITH 8 items in
an array


(project = %@) and (owner = %@) and (status = %@ or status = %@ or status =
%@ or status = %@) and ((initialDescription caseinsensitivelike %@) or
(fragments.fragmentMessage caseinsensitivelike %@))


SQL SHOWN GENERATED WHEN SQL DEBUG IS TURNED ON

<com.webobjects.jdbcadaptor.MicrosoftPlugIn$MicrosoftExpression: "SELECT
t0.contributorEmail, t0.contributorID, t0.contributorName, t0.dateClosed,
t0.dateEntered, t0.dueDate, t0.filePathDirectoryFragment,
t0.filePathURLFragment, t0.fixedInBuild, t0.foundInBuild, t0.hoursWorked,
t0.id, t0.initialDescription, t0.number, t0.ownerID, t0.priorityID,
t0.projectID, t0.statusChangedBy, t0.statusID, t0.typeID FROM WorkItem t0,
WorkFragment T1 WHERE ((UPPER(t0.initialDescription) LIKE UPPER(?) ESCAPE
'\' OR UPPER(T1.fragmentMessage) LIKE UPPER(?) ESCAPE '\') AND (t0.statusID
= ? OR t0.statusID = ? OR t0.statusID = ? OR t0.statusID = ?) AND t0.ownerID
= ? AND t0.projectID = ?) AND t0.id *= T1.workID" withBindings:
1:"something"(initialDescription), 2:"something"(fragmentMessage),
3:131(statusID), 4:126(statusID), 5:2(statusID), 6:1(statusID),
7:1(ownerID), 8:6(projectID)>


ERROR MESSAGE RECEIVED IN RUN WINDOW

com.webobjects.jdbcadaptor.JDBCAdaptorException: EvaluateExpression failed:
<com.webobjects.jdbcadaptor.MicrosoftPlugIn$MicrosoftExpression: "SELECT
t0.contributorEmail, t0.contributorID, t0.contributorName, t0.dateClosed,
t0.dateEntered, t0.dueDate, t0.filePathDirectoryFragment,
t0.filePathURLFragment, t0.fixedInBuild, t0.foundInBuild, t0.hoursWorked,
t0.id, t0.initialDescription, t0.number, t0.ownerID, t0.priorityID,
t0.projectID, t0.statusChangedBy, t0.statusID, t0.typeID FROM WorkItem t0,
WorkFragment T1 WHERE ((UPPER(t0.initialDescription) LIKE UPPER(?) ESCAPE
'\' OR UPPER(T1.fragmentMessage) LIKE UPPER(?) ESCAPE '\') AND (t0.statusID
= ? OR t0.statusID = ? OR t0.statusID = ? OR t0.statusID = ?) AND t0.ownerID
= ? AND t0.projectID = ?) AND t0.id *= T1.workID" withBindings:
1:"something"(initialDescription), 2:"something"(fragmentMessage),
3:131(statusID), 4:126(statusID), 5:2(statusID), 6:1(statusID),
7:1(ownerID), 8:6(projectID)>:
Next exception:SQL State:S0002 -- error code: 8116 -- msg: Argument data
type text is invalid for argument 1 of upper function.)
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • RE: JDBCAdaptor LIKE clause problem
      • From: "Peter Fournier" <email@hidden>
  • Prev by Date: Re: Mapping multiple EOs to one table
  • Next by Date: Re: Problems using primary key as attribute
  • Previous by thread: JDBCAdaptor LIKE clause problem
  • Next by thread: RE: JDBCAdaptor LIKE clause problem
  • Index(es):
    • Date
    • Thread