On Thu, Nov 17, 2005 at 02:51:05PM -0800, Dawn Buie wrote:
> I'm just confused about how I should write code to update the selected
> items to remove the 'v.'
>
> Would I use substring? An example would be much appreciated.
You need a combination of overlay and location. The following will
work
am 17.11.2005, um 14:51:05 -0800 mailte Dawn Buie folgendes:
> Hello-
>
> I have a column of data with the wrong prefix for many items.
If you have 8.1? If yes:
>
> The wrong entries are entered ' /0/v.myimage.jpg'
> While the correct ones are ' /0/myimage.jpg'
>
>
> I need to remove all the
update media_instance set location=replace(location,'v.','')
where location like '%/0/v.%'
For more complex search/replace operations, 8.1 provides an interesting
function, named 'regexp_replace'.
It probably goes unnoticed because although there is a small reference in
the manual in section
Dawn Buie wrote:
> I used:
>
> update media_instance set location=replace(location,'v.','')
> where location like '%/0/v.%'
>
> and that did work-
>
> thank you very much.
>
> it seems to me that the replace function is the same as translate()- no?
>
Right, I forgot your WHERE clause.
Some mo
I used:
update media_instance set location=replace(location,'v.','')
where location like '%/0/v.%'
and that did work-
thank you very much.
it seems to me that the replace function is the same as translate()- no?
On 17-Nov-05, at 3:55 PM, Bricklen Anderson wrote:
Dawn Buie wrote:
Hello-
I'm
Dawn Buie wrote:
> Hello-
> I'm using postgres 7.4
>
> I have a column of data with the wrong prefix for many items.
>
> The wrong entries are entered ' /0/v.myimage.jpg'
> While the correct ones are ' /0/myimage.jpg'
>
>
> I need to remove all the 'v.' characters from this column.
>
>
> I'm
Hello-
I have a column of data with the wrong prefix for many items.
The wrong entries are entered ' /0/v.myimage.jpg'
While the correct ones are ' /0/myimage.jpg'
I need to remove all the 'v.' characters from this column.
I'm able to do a
SELECT * FROM myTable
WHERE location = '%/0/v.%'
Hello-
I'm using postgres 7.4
I have a column of data with the wrong prefix for many items.
The wrong entries are entered ' /0/v.myimage.jpg'
While the correct ones are ' /0/myimage.jpg'
I need to remove all the 'v.' characters from this column.
I'm able to do a
SELECT * FROM myTable
WHERE