Click here to Skip to main content
15,897,371 members
Please Sign up or sign in to vote.
1.52/5 (6 votes)
See more:
This filed
{GIF}{PNG}{JPG}Replace as *.GIF;*.PNG;*.JPG
using sql select replace...........
Posted
Updated 21-Aug-13 4:29am
v2
Comments
Dhruvin Sukhadiya 21-Aug-13 10:14am    
Update your qustion what you are saying Write properly
ridoy 21-Aug-13 10:52am    
not a question.

If the coloumn containg the extention is called "extension", in a table called "MyTable",
you can use replace like this:
SQL
SELECT Replace(Replace(extension, '{', '*.'), '}', ';') 
AS ext 
FROM MyTable


Best,
H
 
Share this answer
 
v4
Comments
Joezer BH 21-Aug-13 10:24am    
5ed!
Herbisaurus 21-Aug-13 10:26am    
Thank you :)
Try this...

SQL
SELECT REPLACE(REPLACE(REPLACE(coulum_extension,'{GIF}','*.GIF'), '{JPG}', "*.JPG"), "{PNG}", "*.PNG") FROM TableExtension ;
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900