[thelist] Interesting SQL Mass update

rudy r937 at interlog.com
Mon Oct 28 10:40:01 CST 2002

> Are you talking Access or SQL Server or MySQL?

because he said asp, my guess is either ms access or ms sql/server

  update yourtable
    set yourcolumn = replace(yourcolumn,' target="_blank"','')
  where yourcolumn like '% target="_blank"%'

use asterisks instead of percents with the access jet engine

note the replace function uses single and double quotes -- be careful which
is which

it may seem that the WHERE clause is superfluous, and that the query will
also work without it, but then it would update every row


More information about the thelist mailing list