• 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
copy from stdin; in migrations
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

copy from stdin; in migrations


  • Subject: copy from stdin; in migrations
  • From: Mark Wardle <email@hidden>
  • Date: Sun, 15 Nov 2009 20:07:19 +0000

Hi all,

Just spent time tidying up my project initialisation ready for production use.

I am using migrations and running

ERXJDBCUtilities.executeUpdateScriptFromResourceNamed(database.adaptorChannel(),
				"initial-data-" +
ERXJDBCUtilities.databaseProductName(database.adaptorChannel()) +
".sql", "RSBusinessLogic");

as part of a second migration for one of my frameworks.

[The first migration is currently always a copy+paste from Entity Modeler]

I can use INSERT with no difficulties, but I thought I'd tidy things
up (*) and judiciously change to

COPY t_role (name, can_login, etc.... ) FROM stdin;
System, true
Power user, false
Flibble, true
\.

This runs if I execute psql -f xxx.sql dbname, and runs if I cut+paste.

It doesn't run when part of a migration [it just hangs]. Am I being
stupid or is this behaviour expected? I'm expecting both the former
and the latter to be correct on this occasion....

Many thanks,

Mark


(*) always a mistake to try to tidy things up at this stage...

--
Dr. Mark Wardle
Specialist registrar, Neurology
Cardiff, UK
 _______________________________________________
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

  • Follow-Ups:
    • Re: copy from stdin; in migrations
      • From: Mark Wardle <email@hidden>
  • Prev by Date: Re: Cenos Linux
  • Next by Date: Re: copy from stdin; in migrations
  • Previous by thread: Re: Cenos Linux
  • Next by thread: Re: copy from stdin; in migrations
  • Index(es):
    • Date
    • Thread