• 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: DB Plugin Question...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DB Plugin Question...


  • Subject: Re: DB Plugin Question...
  • From: Chuck Hill <email@hidden>
  • Date: Mon, 11 Apr 2005 21:57:58 -0700

Ah.  I thought you wanted to upper case the column _names_.  Sorry, read
too quickly.  Looks like Auturo pointed you in the right direction.

Chuck


At 08:14 PM 11/04/2005 -0500, James Cicenia wrote:
>>>>
Well, I need to change the sql it is sending to db2. Caseinsensitive like
creates
a bit of sql like so from this:

qualifier=((companyName caseinsensitivelike '117*') and (contactName
caseinsensitivelike 'abc*')),

 t0 WHERE (UPPER(t0.company_name) LIKE UPPER(?) ESCAPE '\' AND
UPPER(t0.contact_name) LIKE UPPER(?) ESCAPE '\')"

I want it to be like such that I convert it to

 t0 WHERE (UPPER(t0.company_name) LIKE (?) ESCAPE '\' AND
UPPER(t0.contact_name) LIKE (?) ESCAPE '\')"

Notice the missing upper on the binding. I think this will cure a DB2 woe.
So the question is where does wo convert key, etc., to UPPER? My
strategy was such:

	    if(sel.equals(EOQualifier.QualifierOperatorCaseInsensitiveLike) &&
value instanceof String) {
	        theQualifier = new EOKeyValueQualifier(key,
EOQualifier.QualifierOperatorLike, ((String)value).toUpperCase());
	    }
	    else {
	        theQualifier = qualifier;
	    }

which is good so far.. just now need to apply UPPER on the key when it gets
generated.

Does this make sense? Any great paths to look into?

I think I need to find where it converts keys to columns? or better yet
when in converts keys to columns for each qualifier.


- James

On Apr 11, 2005, at 7:29 PM, Chuck Hill wrote:

I'm not sure there is one.  Column names are usually case insensitive.

Chuck

On Apr 11, 2005, at 5:20 PM, James Cicenia wrote:

I am trying to convert the key to something like UPPER(key),
however I can't use EOKeyValueQualifier to set it and I need to
explicitly set it.

Is there a place where I can intercept WebObjects moment
where it converts key to a sql column?

I can't seem to find it in the javadocs.

Thanks,
James Cicenia

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

This email sent to email@hidden

--
Practical WebObjects - a book for intermediate WebObjects developers who
want to increase their overall knowledge of WebObjects, or those who are
trying to solve specific application development problems.
http://www.global-village.net/products/practical_webobjects




<<<<


--

Practical WebObjects - a book for intermediate WebObjects developers
who want to increase their overall knowledge of WebObjects, or those
who are trying to solve specific application development problems.
http://www.global-village.net/products/practical_webobjects


 _______________________________________________
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

References: 
 >Re: DB Plugin Question... (From: Chuck Hill <email@hidden>)
 >DB Plugin Question... (From: James Cicenia <email@hidden>)
 >Re: DB Plugin Question... (From: James Cicenia <email@hidden>)

  • Prev by Date: Re: DB Plugin Question...
  • Next by Date: Re: Wolips
  • Previous by thread: Re: DB Plugin Question...
  • Next by thread: Re: DB Plugin Question...
  • Index(es):
    • Date
    • Thread