Re: [SQL] Search and Replace

Поиск
Список
Период
Сортировка
От Randy D. McCracken
Тема Re: [SQL] Search and Replace
Дата
Msg-id Pine.LNX.4.44.0301091911270.6431-100000@www.srs.fs.fed.us
обсуждение исходный текст
Ответы Re: [SQL] Search and Replace
Список pgsql-novice
On Thu, 9 Jan 2003, Ross J. Reedstrom wrote:

> On Thu, Jan 09, 2003 at 11:00:32AM +0530, Rajesh Kumar Mallah. wrote:
> >
> > any anyone explain whats wrong with the replace based solution to this problem
> > which i posted earlier?
> >
> > did i misunderstood anything?
>
> Probably just overkill - I'm sure it would work, but, based on how the
> question was asked, I guessed that the original questioner was looking
> for a quick, onetime fix sort of thing, and wasn't real comfortable with
> SQL, let alone adding contrib extension products to the installation.
>
> Ross
>
>

Hi Rajesh,

I don't know why but the example you gave me did not work.  Here is what
happened when I tried:

==========

pubs_test=# UPDATE publications SET url = replace( 'www.srs.fs.fed.us' ,
'www.srs.fs.usda.gov' , url )  WHERE url ilike '%www.srs.fs.fed.us%';

ERROR:  Function 'replace(unknown, unknown, text)' does not exist
        Unable to identify a function that satisfies the given argument types
        You may need to add explicit typecasts

==========

Obviously I am a newbie at PostgreSQL (I have also joined the Novice
mailing list to learn more) so I can not tell you why your example did not
work, perhaps someone else with more experience can add some information.

Best,

--rdm




В списке pgsql-novice по дате отправления:

Предыдущее
От: Dave Stewart
Дата:
Сообщение: [SOLVED] 'xactisolevel' not recognized [THANKS!]
Следующее
От: Bruno Wolff III
Дата:
Сообщение: Re: [SQL] Search and Replace