help with sqlite replace function
am trying to update my database table that looks like this
name | file_n开发者_JS百科ame
----------------
name1 | name1\data
what i want to do is, to replace all the name1 from name
found in file_name
column with empty string
update cache set
file_name=replace(file_name,name,'')
where file_name like '%'||name||"%'"
When i execute the query above, i get an empty recordset.
can anybody help me fix this
UPDATE cache SET file_name=replace(file_name, name, '');
Worked without the WHERE clause.
精彩评论