import « SQL « JPA Q&A

1. create fixture using hibernate(not import.sql method)

Is there a way to use java code and those hibernate entity classes to create fixture data. I find using import.sql is not good when it comes to database migration

2. import.sql: Indeed only one liners allowed?

Hi I have tables whith dozens of fields which I want to populate during deploy using hbm2ddl create-drop. I naturally ordered such complex insert statements into several lines. The effect was that the SchemaExport.importScript throws the error "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use ...

3. HIbernate, derby & import.sql

Hi. I have a strange problem with Hibernate and Apache Derby. I am trying to load the import.sql file and run it against a Derby db. My hibernate.cfg.xml file looks like this: org.apache.derby.jdbc.EmbeddedDriver jdbc:derby:safetyinformation;create=true org.hibernate.dialect.DerbyDialect create true When i run the ...

5. import.sql missing from tutorial

6. Multiples import.sql error

7. "/import.sql" and dialect

8. import.sql

9. problems with import.sql and more..

Hi! I am confused about import.sql feature as well a few things around it. i am using version of hibernate that comes with jboss seam 2.0.3.CR1 (version 3.something) Besides that it is jboss AS 4.2.2 GA, Postgres db. I have 2 tables for 2 entitys/classes. None of the tables gets updated with stuff from import.sql if i am using setting

10. import.sql

I'm using JBoss 4.2.2, MySQL 5.0 I'm deploying application with import.sql file which is supposed to be executed by hibernate and populate database with data Problem is import.sql contains data in UTF encoding. And these data is inserted incorrectly. all non-ASCII characters are broken. MySQL database is set up with default UTF8 encoding and collation. I can insert utf data directly ...

11. import.sql imported more than once

I'm using import.sql successfully in an ejb.jar together with JPA. In my persistence.xml I've configured autoddl to 'create'. So when the table doesn't exist, it will be created and data from import.sql will be imported without any problems. If the table already exists, nothing happens - as expected. Now this ejb.jar is bundled with other ejb.jars in an EAR. All other ...

12. import.sql

Hi all, If I wanted to split my import.sql into multiple files and still have that run on startup, how would I go about doing that? My import.sql is getting a little large and I was hoping I could maybe leave it in the same place and have one for each jar file that provides some functionality my web app is ...

13. internationalisation of import.sql