In message <5d4701c4cb88$f8e933c0$a401280a (AT) phx (DOT) gbl>, James Johnson
<anonymous (AT) discussions (DOT) microsoft.com> writes
Quote:
I have a script to remove double quotes in my table,
however, when it gets to the identity column it errors
out. How can I overcome or skip over the identity column
using this script? |
Put a where clause in the information_schema.columns select statement
and check the DATA_TYPE column to include character type columns only.
You cannot use a function such as replace on an integer column, because
replace expects a string as the first input, and of course being an
integer it can never hold a quote anyway so trying to do so will not
only raise an error, but also is not relevant.
--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com
PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org