facebook

HibernateQueryException: unexpected end of subtree

  1. MyEclipse Archived
  2.  > 
  3. Database Tools (DB Explorer, Hibernate, etc.)
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #304190 Reply

    amir55
    Participant

    hi all

    1 – I ahve this error in hibernate usng latest MyEclipse 7.5

    Exception in thread “main” org.springframework.orm.hibernate3.HibernateQueryException: unexpected end of subtree []; nested exception is org.hibernate.hql.ast.QuerySyntaxException: unexpected end of subtree []
    org.hibernate.hql.ast.QuerySyntaxException: unexpected end of subtree []

    my code as this using spring hibernate

    String str = “from one_to_many_bi.Husband”;
    List list = getSession().createQuery(str).list();

    2 – I have entere my full sibscription

    3 – my bibernae/e.cfg.xml

    <?xml version=’1.0′ encoding=’UTF-8′?>
    <!DOCTYPE hibernate-configuration PUBLIC
    “-//Hibernate/Hibernate Configuration DTD 3.0//EN”
    http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd”&gt;

    <hibernate-configuration>

    <session-factory>
    <property name=”connection.username”>root</property>
    <property name=”connection.url”>jdbc:mysql://localhost:3306/amir?autoReconnect=true&profileSQL=false <!– if I set profile to true I get red throws –>
    </property>
    <property name=”connection.autocommit”>true</property>
    <property name=”dialect”>
    org.hibernate.dialect.MySQLDialect
    </property>
    <property name=”myeclipse.connection.profile”>
    MySQL Connection
    </property>
    <property name=”connection.password”>amir</property>
    <property name=”connection.driver_class”>
    com.mysql.jdbc.Driver
    </property>

    <property name=”cache.provider_class”>
    org.hibernate.cache.EhCacheProvider
    </property>
    <property name=”current_session_context_class”>thread</property>
    <property name=”hibernate.transaction.factory_class”>
    org.hibernate.transaction.JDBCTransactionFactory
    </property>
    <property name=”hibernate.transaction.auto_close_session”>true</property>

    <property name=”hibernate.show_sql”>true</property>
    <property name=”hibernate.hbm2ddl.auto”>create</property>

    <mapping resource=”one_to_many_bi/Husband.hbm.xml”
    <mapping resource=”one_to_many_bi/Child.hbm.xml” />
    </session-factory>
    </hibernate-configuration>

    #304197 Reply

    amir55,
    Can you share your project? You can send a mail to support@genuitec.com. Please add ATTN:Shalini in the subject and refer to this post. Also send us the script of the tables your are using along with your with your installation details from MyEclipse > Installation Summary > Installation Details.

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: HibernateQueryException: unexpected end of subtree

You must be logged in to post in the forum log in