Forum OpenACS Q&A: Another 4.6 question

Collapse
Posted by Roger Lockerbie on
Apologies to all if this question is silly.

I have started porting Newsflow from ACS oracle to openACS postgres. when running my newsflow-create.sql, part of the content repository build barfs when trying to create attributes.

In oracle when you defined the column type for CMS you could extend it with constraints ala.

varchar(100) constraint mycms_nn not null.

Now the postgresSQL package thoughtfully tells you that sort of behaviour is not supported and to run the CMS attribute function then add the constraints to the build table columns using ALTER TABLE.

Thats good, but I ended up in such a mess about what had been built and what had not that after trying to drop stuff left right and center, I've given up and am re-installing (yeah!, should have done a backup :( )

The point of this diatribe is:-

Is there away when you run a script in psql (I am doing via \i newsflow-create.sql, that you can see the statement its trying to execute followed by the error message, rather that just the error/success statements. This would make it a lot easier to unwind any failiures. (Unwinding half baked CMS objects is pretty tricky), the drop scripts try and be smart but its pretty hard....

The only other way I can think of is running a block at a time and commenting out the rest, which on a big block like newsflow is a bit of a pain.

Thanks for the help, and thanks to Don, Jun etc for replying to my previous post

Roger.