How to replace char in Ntext field

Discussion in 'Webmaster / Programming' started by sausmus, Jun 15, 2006.

  1. sausmus

    sausmus

    Joined:
    May 24, 2006
    Messages:
    5
    Likes Received:
    0
    I need help on replace char in ntext data type

    Here is the example data
    <qMultipleChoice><qText>The%20AE%20understands%20what%20conditions%20the%20Account%20Manager%20is%20allowed%20to%20sign-off
    20on.</qText><qChoice>Strongly20Disagree</qChoice><qChoice>Disagree
    </qChoice><qChoice>Agree</qChoice><qChoice>Strongly%20Agree</qCh

    I want result look like this(break 2 parts)
    First Column:The Understands what conditions the Account Manager is allowed to sign-off.
    Second Column: Strongly Disagree Disagree Agree Strongly Agree

    This is what i had so far
    Select (SUBSTRING(QuestionText, (PATINDEX(N'%<qText>%', QuestionText) + 7),(PATINDEX(N'%</qText>%', QuestionText) - (PATINDEX(N'%<qText>%', QuestionText) + 7)))) From tblExample

    my result:
    The%20AE%20understands%20what%20conditions%20the%20Account%20Manager%20is%20allowed%20to%20sign-off%20on.

    I have problem replace '%20' and how to make the second column.
    Any Help?
    Thanks
    Shan
     
    sausmus, Jun 15, 2006
    #1
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. roddy1212
    Replies:
    0
    Views:
    755
    roddy1212
    Jul 7, 2005
  2. GreenJelly707

    VB.Net TextBox Find, Replace text???

    GreenJelly707, Oct 3, 2005, in forum: Webmaster / Programming
    Replies:
    1
    Views:
    9,512
    masterkeedu
    Oct 19, 2005
  3. masterkeedu

    I need to Replace portions of query results (mysql, php)

    masterkeedu, May 15, 2007, in forum: Webmaster / Programming
    Replies:
    2
    Views:
    1,035
  4. rocckky

    how to marshal a struct with a char arrray in VC++ CLR

    rocckky, May 30, 2007, in forum: Webmaster / Programming
    Replies:
    0
    Views:
    1,581
    rocckky
    May 30, 2007
  5. akhil

    Auto Increment Field or Identity Field In MS SQL Server

    akhil, Mar 5, 2011, in forum: Webmaster / Programming
    Replies:
    0
    Views:
    2,532
    akhil
    Mar 5, 2011
Loading...

Share This Page