Problem in creating the database

Asked by Omai bigee

When I run the following command:
psql -U postgres -d simdb -f setupSimDB.sql

With psql version 9.4.6 I encounter the following problem.

ALTER FUNCTION
psql:setupSimDB.sql:178: ERROR: syntax error at or near "."
LINE 11: ...ELECT pg_total_relation_size(\'' || user_name || '.scenarios...
                                                              ^
psql:setupSimDB.sql:180: ERROR: function administration.calculate_campaign_size(integer) does not exist
CREATE FUNCTION
ALTER FUNCTION
CREATE FUNCTION
ALTER FUNCTION
CREATE FUNCTION
ALTER FUNCTION
GRANT
CREATE FUNCTION
CREATE FUNCTION
SET
psql:setupSimDB.sql:1864: ERROR: syntax error at or near "\"
LINE 95: type_string text DEFAULT \'\'
                                       ^

Any suggestions?
Thanks in advance.

Question information

Language:
English Edit question
Status:
Solved
For:
openWNS Wrowser Edit question
Assignee:
No assignee Edit question
Solved by:
Maciej Muehleisen
Solved:
Last query:
Last reply:
Revision history for this message
Best Maciej Muehleisen (mue-comnets) said :
#1

Please uninstall PSQL 9 and use PSQL 8 as described here under Ubuntu 12.04 (also works for 14.04, not tried with newer versions):

http://docs.openwns.org/gettingStarted/postgresql.html

Sometimes there are problems deinstalling PSQL 9. You then might want to start over with a fresh system. This might also help:

http://stackoverflow.com/questions/2748607/how-to-thoroughly-purge-and-reinstall-postgresql-on-ubuntu

Revision history for this message
Omai bigee (o-maib-g) said :
#2

Indeed I somehow skipped reading the line saying that PSQL9 was not supported.
As per my experience, Debian 8 with Postgresql 9 definitely does NOT work.

I started again with Ubuntu 12.04 and everything worked fine.

Thanks a lot for your help!

Revision history for this message
Omai bigee (o-maib-g) said :
#3

Thanks Maciej Muehleisen, that solved my question.