-->
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.  [ 4 posts ] 
Author Message
 Post subject: CreateSQLQuery problem...
PostPosted: Wed Jul 12, 2006 11:35 am 
Newbie

Joined: Mon Jun 12, 2006 8:44 am
Posts: 13
I'm doing this:

string strSql = "select {nf.*} from ADFinance.Faturamento.NotaFiscal {nf}";
IQuery q = NHibernateSessionManager.Instance.GetSession().CreateSQLQuery(strSql, "nf", typeof(NotaFiscal));

Assert.Greater(q.List().Count, 0);


I'm receiving the following erro:

ADFinance.Testes.Core.Faturamento.NotaFiscalTestes.SelecionaComCapaLote : NHibernate.ADOException : error in FindBySQL
----> System.Data.OracleClient.OracleException : ORA-00933: SQL command not properly ended

Does anyone know what is the problem??


Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp

Hibernate version:

Mapping documents:

Code between sessionFactory.openSession() and session.close():

Full stack trace of any exception that occurs:

Name and version of the database you are using:

The generated SQL (show_sql=true):

Debug level Hibernate log excerpt:


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 13, 2006 9:16 am 
Newbie

Joined: Mon Jun 12, 2006 8:44 am
Posts: 13
anyone know??


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 14, 2006 3:09 pm 
Newbie

Joined: Mon Jun 12, 2006 8:44 am
Posts: 13
i need some help...


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jul 14, 2006 3:33 pm 
Regular
Regular

Joined: Wed Jun 21, 2006 3:13 pm
Posts: 110
Enable show_sql and look at the generated SQL statement. Attempt to run that in SQL*Plus

You can enable show_sql in your nhibernate config section.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 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.