PDA

View Full Version : Initialize MySQL database on cloud foundry



Chesta
Jul 20th, 2011, 03:58 AM
Hi,

I am trying to initialize database in my application uploaded on cloud foundry using <jdbc:initialize> tag:-

<jdbc:initialize-database data-source="dataSource" ignore-failures="ALL" enabled="true">
<jdbc:script location="classpath:/com/sample/model/scripts.sql" execution="INIT"/>
</jdbc:initialize-database>



Still I am geting error: Base table or view not found, message from server: "Table 'd3aa5fdf4ea2240389ee972a6b5de161e.EMP' doesn't exist"

Please help me in solving this problem.

Thanks in advance.
Chesta

hwilson
Sep 19th, 2011, 06:33 AM
I am not really familiar with logging a database to a cloud service.

The problem probably lies with your database not connecting to the server properly. You probably should check on the ports just to be extra sure that the tables are going to where they should be rather than the wrong destination.

Or you might want to manually set where it is looking so that you really get the proper tables.

placidus
Oct 23rd, 2011, 04:12 PM
hi it's look like you are using

<database>.<tablename> =>> for Eg - Organisation.EMP d3aa5fdf4ea2240389ee972a6b5de161e.EMP


If it's the case try to used with out the database name ->> like create table EMP .........

are used hibernate ?

are you have include the database creation script ?


Placi.