Solved

Update a part of a field.

Posted on 2011-09-02
2
279 Views
Last Modified: 2012-05-12

I want to change the end part of the filename
from:
0000229_0.pjpeg
to:
0000229_0.jpg

How do I do this? I know this won't:

UPDATE Nop_Product
SET AdminComment = 'jpg'
WHERE AdminComment = 'pjpeg'

thanks
0
Comment
Question by:MikeMCSD
2 Comments
 
LVL 22

Accepted Solution

by:
pivar earned 500 total points
ID: 36476150
Hi,

Try


UPDATE Nop_Product
SET AdminComment = REPLACE(AdminComment, '.pjpeg', '.jpg')
WHERE AdminComment LIKE '%.pjpeg'


/peter
0
 
LVL 16

Author Comment

by:MikeMCSD
ID: 36476178
perfect, . .  thank you
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Everyone has problem when going to load data into Data warehouse (EDW). They all need to confirm that data quality is good but they don't no how to proceed. Microsoft has provided new task within SSIS 2008 called "Data Profiler Task". It solve th…
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now