Welcome to dbForumz.com!
FAQFAQ    SearchSearch      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

creating mysql schema in java code

 
   Database Forums (Home) -> Java RSS
Next:  ODBC Driver for Linux  
Author Message
cleveridea

External


Since: Sep 16, 2005
Posts: 1



(Msg. 1) Posted: Fri Sep 16, 2005 8:50 am
Post subject: creating mysql schema in java code
Archived from groups: comp>lang>java>databases (more info?)

We have developed an application in java running on jboss that uses
mysql as the database with hibernate persistence. Hibernate
automatically creates all the associated mysql tables, but at present
we have to create a schema manually using mysql's admin GUI on a new
machine. We want to make deployment of the application (built into a
single .war file) as automated as possible.

Is there a way to create the initial 'schema' (CREATE DATABASE) using
java code rather than manually? E.g. through the hibernate or JDBC
libraries.

 >> Stay informed about: creating mysql schema in java code 
Back to top
Login to vote
John Currier

External


Since: Jun 03, 2005
Posts: 12



(Msg. 2) Posted: Mon Sep 19, 2005 6:26 am
Post subject: Re: creating mysql schema in java code [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

wrote:
> We have developed an application in java running on jboss that uses
> mysql as the database with hibernate persistence. Hibernate
> automatically creates all the associated mysql tables, but at present
> we have to create a schema manually using mysql's admin GUI on a new
> machine. We want to make deployment of the application (built into a
> single .war file) as automated as possible.
>
> Is there a way to create the initial 'schema' (CREATE DATABASE) using
> java code rather than manually? E.g. through the hibernate or JDBC
> libraries.

Google for hbm2ddl.auto.

John
http://schemaspy.sourceforge.net

 >> Stay informed about: creating mysql schema in java code 
Back to top
Login to vote
Alfred

External


Since: Apr 12, 2005
Posts: 10



(Msg. 3) Posted: Tue Sep 27, 2005 3:55 pm
Post subject: Re: creating mysql schema in java code [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

wrote:
> ...
> Is there a way to create the initial 'schema' (CREATE DATABASE) using
> java code rather than manually? E.g. through the hibernate or JDBC
> libraries.

Ask the MySQL Guide.

Good luck
 >> Stay informed about: creating mysql schema in java code 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
Read Database schema with java - I m searching for a methode to read a database schema with java: Tables, Relations, Tablefield, Primary Keys, NULL/ NOT Null. did u know any consept. did u know a method with hibernate

mysql-connector-java-3.1.7-bin.jar - I am using : mysql-connector-java-3.1.7-bin.jar to connect to a MySQL database on a MySQL server ver 4.0.25. After Mysql 4.1.1 there is a new password hashing algorithm involved. Does anyone know if mysql-connector-java-3.1.7-bin.jar will work with..

Connecting to mysql via Java -

MySQL and Java : Column not found - I have a database called dbuild and a table called news with sample entries added by the DB_News.java So I have managed to communicate to the MySQL database and do stuff. Here is my new problem when I try and get "article" which is a "...

Create Database After Connection Java -- Mysql - Hi friends, I want to know that is it possible to create database after connecting to mysql . I am using jdbc:odbc driver and front end tool is java. If it is then please say me.
   Database Forums (Home) -> Java All times are: Pacific Time (US & Canada)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You can edit your posts in this forum
You can delete your posts in this forum
You can vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]