SQL Server 2008R2
I need to strip the HTML from my notes field. I see several things online about functions that will do this, but they look fairly lengthy and I cant figure out where they would be placed in the statement.
Below is my simple query that works except all the HTML tag that is being pulled through.
Im looking for the simplest way to plug into my statement and only show my notes.
SELECT COMPANY,REF,USERID, CONVERT(VARCHAR(MAX),CONVERT(VARBINARY(MAX),CONTHIST.NOTES)) AS NOTES
FROM CONTACT1 INNER JOIN CONTACT2 ON CONTACT1.ACCOUNTNO=CONTACT2.ACCOUNTNO INNER JOIN CONTHIST ON CONTACT2.ACCOUNTNO=CONTHIST.ACCOUNTNO
WHERE SRECTYPE LIKE'A' AND REF LIKE'%intRlox (%' AND USERID NOT like'clicks'