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.  [ 1 post ] 
Author Message
 Post subject: parameters not being inserted into query
PostPosted: Sat Apr 05, 2008 6:41 pm 
Newbie

Joined: Sat Apr 05, 2008 12:54 pm
Posts: 3
Tblusers users = new Tblusers();
users.Login = "sgj320";
users.Password = "password";
ICriteria results = session.CreateCriteria(typeof(Tblusers))
.Add(Example.Create(users));
IList user = results.List();
return user.Count;

whats wrong with that it keeps not filling in the blanks.
SELECT this_.userid as userid0_0_, this_.username as username0_0_, this_.Password as Password0_0_, this_.email as email0_0_, this_.address as address0_0_, this_.name as name0_0_, this_.surname as surname0_0_, this_.town as town0_0_, this_.postcode as postcode0_0_, this_.telephone as telephone0_0_, this_.mobile as mobile0_0_ FROM Tblusers this_ WHERE (this_.username = ? and this_.Password = ?) ]
Positional parameters: 0 sgj320
0 password

Am using latest version of nhibernate and asp.net 3.5.
why? I can add records so am assumming it's something to do with that


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

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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.