From: Michael Brusser <michael@synchronicity.com>
To: pgsql-admin@postgresql.org
Subject: Problem with view upgrading from 7.2 to 7.3
Date: Mon, 17 Mar 2003 16:22:14 -0500
Message-ID: <DEEIJKLFNJGBEMBLBAHCAEDDCPAA.michael@synchronicity.com> (raw)
Hi,
I am upgrading Postgres from version 7.2.1 to 7.3.2
I use pg_dump (the 7.3.2 version) to dump the old database
into the file. I use psql to load it into the new server.
Generally it seem to work, but it breaks while attempting to load
one view definition. Server complains about nonexistant function -
varchar(int), as far as I remember.
It appears that some casting is no longer supported.
This is the fragment from the dump file that results in error:
CREATE VIEW v_note_links AS
SELECT note_links_aux.nl_id AS id, note_links_aux.nl_obj_url AS obj_url,
((('sync:///Note/SyncNotes/'::"varchar" || note_links_aux.nt_note_name)
|| '/'::"varchar") || "varchar"(note_links_aux.nl_note_id)) AS note_url,
note_links_aux.nt_note_name AS note_name, note_links_aux.nl_note_id AS
note_id, note_links_aux.nt_obj_name AS obj_name, note_links_aux.nl_obj_id
AS obj_id FROM note_links_aux;
------------------------------------------
There's no problem if I try to manually create the view in the way it was
created in the old database:
CREATE VIEW v_note_links AS
SELECT nl_id AS id
,nl_obj_url AS obj_url
,'sync:///Note/SyncNotes/' || nt_note_name || '/'
|| nl_note_id AS note_url
,nt_note_name AS note_name
,nl_note_id AS note_id
,nt_obj_name AS obj_name
,nl_obj_id AS obj_id
FROM note_links_aux ;
-----------------------------------------------
I would appreciate any help on how to handle this problem.
Mike.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: michael@synchronicity.com
Subject: Re: Problem with view upgrading from 7.2 to 7.3
In-Reply-To: <DEEIJKLFNJGBEMBLBAHCAEDDCPAA.michael@synchronicity.com>
References: <DEEIJKLFNJGBEMBLBAHCAEDDCPAA.michael@synchronicity.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox