Viewing 15 posts - 46 through 60 (of 62 total)
derek.colley (2/21/2012)
So replace:
update documentbody
set bodytext = @myvar
where @prereplace is not null
with:
update...
February 21, 2012 at 8:22 am
I'm trying to update the bodytext column of the documentbody table for rows where this string is found.
<body><p><aname="productLink" class="productLink" code1="1463513" >ProductLink</a></p></body>
with
<body><p><aname="productLink" class="productLink" code1="1463513" ode2="4567891">ProductLink</a></p></body>
the update statement below, updates every...
February 20, 2012 at 4:11 pm
Thanks.
I'll try to describe the problem in detail.
Users are able to enter a product code (code1 and code2 as a pair) into a document. There may be more than one...
February 17, 2012 at 10:58 am
I wished a simple replace was the solution. I was far too simplistic in my initial post.
I've figured out a few things to get me started.
From this
<body><p><a code1="111111" code2="222222"</a></p>
</body>
I...
February 16, 2012 at 3:36 pm
Ken McKelvey (4/7/2011)
Something like the following:
DELETE docBodyVersion
WHERE EXISTS
(
SELECT *
FROM document...
April 7, 2011 at 2:35 pm
RP_DBA (2/23/2011)
insert into userprofile(userID, fieldID, value,)
select distinct userID, 1000, 'external'
from user
where not exists...
February 24, 2011 at 10:14 am
I tried this...
if exists(select email from user where
email LIKE '%@hotmail%' or
email LIKE '%@gmail%' or
email LIKE '%@googlemail%' or
email LIKE '%@yahoo%')
insert into userprofile(userID, fieldID, value, primaryVal, levelID)
select userID, 5001,...
February 23, 2011 at 3:33 pm
RP_DBA (2/23/2011)
February 23, 2011 at 3:07 pm
Lowell (9/24/2010)
then you can copy/paste the commands and run...
September 24, 2010 at 3:01 pm
Lowell (9/23/2010)
select month(dateadd(s,creationDate/1000,'1970-01-01')) as mnth, year(dateadd(s,creationdate/1000,'1970-01-01')) as yr
FROM
(
...
September 24, 2010 at 2:14 pm
I have resolved this with the following statement
update bodyTextTable
set bodyText = cast(replace(cast(bodyText as nvarchar(max)),'/themes/old/', '/themes/new/') as ntext)
I had to cast ntext to nvarchar and cast it back to ntext after...
September 15, 2010 at 10:33 am
Steve Jones - Editor (9/15/2010)
Use a SELECT to debug this
SELECT bodytext
, replace (bodyText, '%/themes/old/%', '%/themes/new%')
from bodyTextTable
Your select statement returns
Msg 8116, Level 16, State 1, Line...
September 15, 2010 at 10:13 am
Viewing 15 posts - 46 through 60 (of 62 total)