Skip to Main Content

Integration

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

JPA - LIKE Statement with wildcard

533988Sep 15 2006 — edited Sep 19 2006
Hi,

I'm trying to use the LIKE statement with JPA. What I want to do is get all the items that have a name that matchs the keyword 'og' for example ('Dog', 'Big dog'...). If I write that :

query = em.createQuery("SELECT i FROM Item i WHERE i.name LIKE :keyword");
query.setParameter("keyword", keyword);

That will take the items that have the exact keword (in my example only 'og' will appear). I've tried to use the wildcards % but id doesn't work :

query = em.createQuery("SELECT i FROM Item i WHERE i.name LIKE '%:keyword%'");
query = em.createQuery("SELECT i FROM Item i WHERE i.name LIKE %:keyword%");

Does anybody knows how to use the LIKE statement with wildcards ? And by the way, is there a way to ignore the case of my keyword ('og' or 'OG' should give the same result).

Thanks,

Antonio Goncalves

Comments

807559
Solaris 10 runs both Solaris 8 and 9 Container software. yust download the correct software from : http://www.sun.com/software/solaris/containers/getit.jsp

There is lots of documentation on how to configure but its no different then a native zones/container.
You can even create a Solaris 10 zone (not the same as native) using the solaris 9 container as a template.

I've used it very succesfully to migrate a number of old solaris 8 and 9 servers and had no problems what so ever.
800582
Thanks,

I have a flar file from a system long gone. They want to use it to create a Solaris 9 container on their Solaris 10 server. The file is perhaps from 2005. Lets hope it can work.
Thanks.
807740
You can get a flar for Solaris 9 on the same page as the container download btw. Same link as above [http://www.sun.com/software/solaris/containers/getit.jsp|http://www.sun.com/software/solaris/containers/getit.jsp]
800582
They need to have that old flar file. It has software in it which can not be reproduced. It needs to be that old flar file. Is that not workable?
807559
if you have the sol9 container sw installed ok on sol10, you should be able to use the flar ok. i have done so with some older 8/9 images. validate you have enough free space. also, make sure that the key items you need to work from your old flar are not things that interact with the kernel (drivers, etc).
807559
Also you might consider setting the hostid, this is easily overlooked. It might not be nessesary butin some cases (license) this might be relevant.
1 - 6
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Oct 17 2006
Added on Sep 15 2006
4 comments
54,496 views