Domanda

I'm trying to use the Play 2 Framework and connect to my IBM iSeries DB2 database. I seem to be able to make a connection work. But, when I load the application and it tries to run evolution, it fails with the following error: SQLException: [SQL0204] PLAY_EVOLUTIONS in (database name) type *FILE not found.

I've looked at several questions but can't find an answer:

  1. Using Play framework 2 with DB2 (AS400 or LUW)
  2. Play Framework and DB2
  3. What's the proper way to generate evolutions table in DB on Play
    Framework 2.0.3?

The last question was posted by t0mppa in Oct 2012. He says he figured out a way to do it but did not share his method other than to say he worked with the evolutions source and created a solution. I'm not that good.

I feel that if I could just the table definition then maybe I could build the table manually and have it work.

Thanks

Bob

È stato utile?

Soluzione

You could probably also just disable evolutions and create database directly.

By overriding properties you could have not only development and production configurations, but several development configurations -- whatever you need.

example: ~run -Dconfig.resource=development-local-db2.conf

See more from here

http://www.playframework.com/documentation/2.2.x/ProductionConfiguration

Altri suggerimenti

I've managed to get a table created that seems to let Evolutions get beyond this problem. I submitted the follow sql statement using STRSQL from the iSeries command line:

CREATE TABLE library/PLAY_EVOLUTIONS (APPLY_SCRIPT CHAR ( 5000)
NOT NULL WITH DEFAULT, REVERT_SCRIPT CHAR ( 5000) NOT NULL WITH
DEFAULT, "HASH" CHAR ( 5000) NOT NULL WITH DEFAULT, "ID" BIGINT NOT
NULL WITH DEFAULT)

I'm not sure that the field sizes are correct (probable not) or big enough.

Now, on to the next problem...

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top