[SQL] Very strange postgresql behaviour

2007-01-29 Thread Arnau
es: A lot of rules that I don't paste as matter of length. Do you have any idea about how I can fix this? -- Arnau ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match

Re: [SQL] help with version checking

2006-12-29 Thread Arnau
t */ /* The last actions ALWAYS MUST BE: SELECT update_version(); DROP FUNCTION check_version(); DROP FUNCTION update_version(); to update the script version and remove the helper functions */ SELECT update_version(); DROP FUNCTION check_version(); DROP

Re: [SQL] help with version checking

2006-12-28 Thread Arnau
Arnau wrote: Tom Lane wrote: Arnau <[EMAIL PROTECTED]> writes: I don't want, if it's possible, to create a function. Unlike Oracle, PG makes a strong distinction between SQL and programmable languages (including plpgsql). You can't write plpgsql code without putti

Re: [SQL] help with version checking

2006-12-28 Thread Arnau
Tom Lane wrote: Arnau <[EMAIL PROTECTED]> writes: I don't want, if it's possible, to create a function. Unlike Oracle, PG makes a strong distinction between SQL and programmable languages (including plpgsql). You can't write plpgsql code without putti

Re: [SQL] help with version checking

2006-12-28 Thread Arnau
x27;This script needs Agenda version 1.0.0.0, detected version %', v_version; END IF; END; $$ LANGUAGE PLPGSQL; I don't want, if it's possible, to create a function. I just want to check a value stored in a table and if doesn't match the expected one th

[SQL] help with version checking

2006-12-28 Thread Arnau
or near "IF" at character 7 psql:upgrade_agenda.sql:11: WARNING: there is no transaction in progress COMMIT Anybody knows how I can do this or which is the best way to do it? Thank you very much -- Arnau ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq