0

i have html code which i need to update in one clob column , how can i convert it in sql update string? My second question is that how to insert ® and & which exist in this html code.

<html>
<head>
<style></style>
</head>
<body>
     <div>
      <div align="center" style="font-size:11pt;font-family:Calibri,sans-serif;">
            <b> card<sup><font size='3'>&reg;</font></sup>  Card  Notification</b>
            <br />
        </div>
        <hr />
        <p style="font-size:11pt;font-family:Calibri,sans-serif;">
            The online statement for your  card provided by {company name} and issued by Com is now available. Select the Account Maint. &amp; Statement tab to view your statement.
        </p>
        <p style="font-size:10pt;font-family:Calibri,sans-serif;">
            Equal Opportunity Lender.
        </p>
        <p style="font-size:10pt;font-family:Calibri,sans-serif;">
            This Card is issued  International Incorporated.
        </p>
      </div>
  </body>
</html>  

1 Answer 1

1

One option would be to use quotation. If you use sqlplus

set define off
update my table 
set my_clob_column = q'[ <html>
<head>
<style></style>
</head>
<body>
     <div>
      <div align="center" style="font-size:11pt;font-family:Calibri,sans-serif;">
            <b> card<sup><font size='3'>&reg;</font></sup>  Card  Notification</b>
            <br />
        </div>
        <hr />
        <p style="font-size:11pt;font-family:Calibri,sans-serif;">
            The online statement for your  card provided by {company name} and issued by Com is now available. Select the Account Maint. &amp; Statement tab to view your statement.
        </p>
        <p style="font-size:10pt;font-family:Calibri,sans-serif;">
            Equal Opportunity Lender.
        </p>
        <p style="font-size:10pt;font-family:Calibri,sans-serif;">
            This Card is issued  International Incorporated.
        </p>
      </div>
  </body>
</html>  ]' 
where ........... 
Sign up to request clarification or add additional context in comments.

7 Comments

yeah this is the way to get the solution, just one thing need to ask that how to handle &amp; &reg; .Your solution is working but only need to insert &amp; &reg;, that is there in html code..do you know that?
if you use sqlplus, then use set define off. I updated the post
@vim then this is a Toad question. It must have a way to disable substitution variables or to use a different character. Top hit: support.quest.com/toad-for-oracle/kb/11560/…
@vim, you can use Toad the same, but run it as script ( F5 )
@vim, you are very welcome. glad that it helped.
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.