• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
[SOLVED] Re: Very weird migrations behavior
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[SOLVED] Re: Very weird migrations behavior


  • Subject: [SOLVED] Re: Very weird migrations behavior
  • From: Ângelo Andrade Cirino <email@hidden>
  • Date: Sat, 02 May 2015 10:16:19 -0300

Setting the driver and plugin in the connection dictionary solved the problem. Shame on me.

Em 01/05/2015, à(s) 23:41, Chuck Hill <email@hidden> escreveu:

Using a very, very old Wonder I see this

CREATE TABLE "_dbupdater" ( 
"lockowner" VARCHAR(100), 
"modelname" VARCHAR(100) CONSTRAINT NOT_NULL__dbupdater__modelname NOT NULL, 
"updatelock" INTEGER CONSTRAINT NOT_NULL__dbupdater__updatelock NOT NULL, 
"version" INTEGER CONSTRAINT NOT_NULL__dbupdater__version NOT NULL )

ALTER TABLE "_dbupdater" ADD CONSTRAINT "unique_model" UNIQUE("modelname") DEFERRABLE INITIALLY DEFERRED

I don’t see the primary key constant getting added.

Chuck


[2015-05-01 19:27:45,930] <main> ERXJDBCUtilities – Executing 


On 2015-05-01, 7:25 PM, "Ângelo Andrade Cirino" wrote:

For instance, this

"modelname" VARCHAR(100) CONSTRAINT NOT_NULL__dbupdater__modelname NOT NULL,

should be

"modelname" VARCHAR(100) _dbupdater.modelname NOT NULL,
 
and this

ALTER TABLE "_DBUPDATER" ADD CONSTRAINT "PRIMARY_KEY__dbupdater_modelname" PRIMARY KEY ("MODELNAME") NOT DEFERRABLE INITIALLY IMMEDIATE;

should be

ALTER TABLE "_DBUPDATER" PRIMARY KEY ("MODELNAME") NOT DEFERRABLE INITIALLY IMMEDIATE;

There are spurious additions of CONSTRAINT NOT_NULL_ and ADD CONSTRAINT PRIMARY_KEY_ to the SQL.

I forgot to mention my environment

Yosemite 10.10.3
Eclipse 4.4.2
FrontBase
Wonder and WOLips in sync with the master branches.

Em 01/05/2015, à(s) 23:17, Chuck Hill <email@hidden> escreveu:

I am not seeing anything wrong there.

On 2015-05-01, 7:11 PM, "Ângelo Andrade Cirino" wrote:

I’ve been using migrations for a long time, but today I had a problem that left me completely in the dark. See the SQL being generated:

SET TRANSACTION ISOLATION LEVEL SERIALIZABLE, LOCKING PESSIMISTIC;

CREATE TABLE "_dbupdater" (
"lockowner" VARCHAR(100),
"modelname" VARCHAR(100) CONSTRAINT NOT_NULL__dbupdater__modelname NOT NULL,
"updatelock" INTEGER CONSTRAINT NOT_NULL__dbupdater__updatelock NOT NULL,
"version" INTEGER CONSTRAINT NOT_NULL__dbupdater__version NOT NULL
);

ALTER TABLE "_DBUPDATER" ADD CONSTRAINT "PRIMARY_KEY__dbupdater_modelname" PRIMARY KEY ("MODELNAME") NOT DEFERRABLE INITIALLY IMMEDIATE;

COMMIT;

Is it possible that there is a bug in EOSynchronizationFactory?

Angelo

Ângelo Andrade Cirino
email@hidden

"O homem sensato se adapta ao mundo. O insensato insiste em tentar adaptar o mundo a ele. Todo o progresso depende, portanto, do homem insensato"
Sir George Benard Shaw

"The reasonable man adapts himself to the world: the unreasonable one persists in trying to adapt the world to himself. Therefore all progress depends on the unreasonable man."
Sir George Benard Shaw



Ângelo Andrade Cirino
email@hidden

"O homem sensato se adapta ao mundo. O insensato insiste em tentar adaptar o mundo a ele. Todo o progresso depende, portanto, do homem insensato"
Sir George Benard Shaw

"The reasonable man adapts himself to the world: the unreasonable one persists in trying to adapt the world to himself. Therefore all progress depends on the unreasonable man."
Sir George Benard Shaw



Ângelo Andrade Cirino
email@hidden

"O homem sensato se adapta ao mundo. O insensato insiste em tentar adaptar o mundo a ele. Todo o progresso depende, portanto, do homem insensato"
Sir George Benard Shaw

"The reasonable man adapts himself to the world: the unreasonable one persists in trying to adapt the world to himself. Therefore all progress depends on the unreasonable man."
Sir George Benard Shaw


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Very weird migrations behavior (From: Ângelo Andrade Cirino <email@hidden>)
 >Re: Very weird migrations behavior (From: Chuck Hill <email@hidden>)
 >Re: Very weird migrations behavior (From: Ângelo Andrade Cirino <email@hidden>)
 >Re: Very weird migrations behavior (From: Chuck Hill <email@hidden>)

  • Prev by Date: Re: Very weird migrations behavior
  • Next by Date: Using Ivy to manage dependencies in WO [was: Using WO with modern dependency management]
  • Previous by thread: Re: Very weird migrations behavior
  • Next by thread: Re: OT: The Beers of WOWODC
  • Index(es):
    • Date
    • Thread