-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: how works method find(query,objet[],Type[])?
PostPosted: Fri Apr 22, 2005 11:00 am 
Newbie

Joined: Mon Aug 09, 2004 8:31 am
Posts: 8
Location: dijon
Read the rules before posting!
http://www.hibernate.org/ForumMailingli ... AskForHelp

Hibernate version:2..

hello,

I do not understand how the method upper works, is any body could give me an exemple?

thanks


Top
 Profile  
 
 Post subject:
PostPosted: Fri Apr 22, 2005 12:47 pm 
Senior
Senior

Joined: Mon Apr 04, 2005 8:04 am
Posts: 128
Location: Manchester, NH USA
From the Javadoc:
Quote:
Execute a query with bind parameters. Binding an array of values to "?" parameters in the query string.

Parameters:
query - the query string
values - an array of values to be bound to the "?" placeholders (JDBC IN parameters).
types - an array of Hibernate types of the values


For example:

Code:
s.find ("from User where firstName = ?", new Object[]{"foo"}, new Type[]{Hibernate.STRING});


Does that make sense?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.