-->
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: Postgres schema problem
PostPosted: Wed Dec 13, 2006 7:54 pm 
Newbie

Joined: Thu Dec 02, 2004 2:13 pm
Posts: 10
Hello, I am having a problem with postgres and schemas. I am using annotations. The annotations for the class is:
@Entity
@Table(name= "iq2_product", schema = "public", uniqueConstraints = {})

I am getting an error complaining about schema "this_" does not exist.

Caused by: org.postgresql.util.PSQLException: ERROR: schema "this_" does not exist

My config file is as follows:

Code:
<bean id="sessionFactory"
      class="org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBean">
      <property name="dataSource" ref="dataSource" />
      <property name="annotatedClasses">
         <list>
            <value>com.pizza73.model.ProductCategory</value>
            <value>com.pizza73.model.Order</value>
            <value>com.pizza73.model.OrderItem</value>
            <value>com.pizza73.model.Product</value>
            <value>com.pizza73.model.ProductDetail</value>
            <value>com.pizza73.model.ProductProperty</value>
            <value>com.pizza73.model.Shop</value>
            <value>com.pizza73.model.CallCenterAgent</value>
            <value>com.pizza73.model.OnlineCustomer</value>            
            <value>com.pizza73.model.Role</value>                        
            <value>com.pizza73.model.Driver</value>
            <!--
               CODE VALUE MAPPINGS
            -->
            <value>com.pizza73.model.codevalue.SizeCV</value>
            <value>com.pizza73.model.codevalue.CityCV</value>
         </list>

      </property>

      <property name="hibernateProperties">
         <props>
            <prop key="hibernate.dialect">@HIBERNATE-DIALECT@</prop>
            
            <!--<prop key="hibernate.query.substitutions">
               true 'Y', false 'N'
            </prop>
            -->
            <prop key="hibernate.show_sql">true</prop>
            <!-- Create/update the database tables automatically when the JVM starts up
               <prop key="hibernate.hbm2ddl.auto">update</prop> -->
            <!-- Turn batching off for better error messages under PostgreSQL for dev only -->
               <prop key="hibernate.jdbc.batch_size">0</prop>
         </props>
      </property>
      
      
   </bean>



Any ideas as to what I'm doing wrong?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 13, 2006 8:10 pm 
Newbie

Joined: Thu Dec 02, 2004 2:13 pm
Posts: 10
Turns out it's a problem with the way I am using composite keys.

I'll post that question in a new topic.[/code]


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.