Results 1 to 6 of 6
  1. #1
    Join Date
    Dec 2003
    Posts
    46

    Unanswered: How do I post the ' character into a LongText data field?

    I need to update the string in a longtext field. NewString = "This is a 'test'"

    I can't figure out how to use an escape character to identify the string with " ' " and then also include the " ' " character inside the string.

    Can anybody help me?

    Thanks,

    Alex

  2. #2
    Join Date
    Nov 2004
    Location
    on the wrong server
    Posts
    8,835
    Provided Answers: 6
    ''

    This respnse is too short
    “If one brings so much courage to this world the world has to kill them or break them, so of course it kills them. The world breaks every one and afterward many are strong at the broken places. But those that will not break it kills. It kills the very good and the very gentle and the very brave impartially. If you are none of these you can be sure it will kill you too but there will be no special hurry.” Earnest Hemingway, A Farewell To Arms.

  3. #3
    Join Date
    Dec 2003
    Posts
    46

    I wish it was that easy...

    I need to paste this entire string (including the ' characters) into the field.

    Notice the criterie in the where clause;

    SELECT dbo.syStudent.LastName, dbo.syStudent.FirstName, SUM(dbo.AdEnrollSched.CreditsAttempt) AS CreditsAttempted
    FROM dbo.AdEnrollSched INNER JOIN
    dbo.syStudent ON dbo.AdEnrollSched.SyStudentID = dbo.syStudent.SyStudentID
    WHERE (dbo.AdEnrollSched.GPACalc = 1) AND (dbo.syStudent.SyCampusID = 8) AND (dbo.AdEnrollSched.Status = 'P' OR
    dbo.AdEnrollSched.Status = 'D')
    GROUP BY dbo.syStudent.LastName, dbo.syStudent.FirstName
    HAVING (SUM(dbo.AdEnrollSched.CreditsAttempt) = 12)

  4. #4
    Join Date
    Feb 2004
    Location
    Bangalore, India
    Posts
    250
    hi

    To INSERT you can use

    INSERT INTO yourTable(yourField) VALUES ('D''souza')


    and SELECT is

    SELECT yourField FROM yourTable WHERE yourField = 'D''souza'
    Cheers....

    baburajv

  5. #5
    Join Date
    Nov 2004
    Location
    on the wrong server
    Posts
    8,835
    Provided Answers: 6
    Like I said ''
    “If one brings so much courage to this world the world has to kill them or break them, so of course it kills them. The world breaks every one and afterward many are strong at the broken places. But those that will not break it kills. It kills the very good and the very gentle and the very brave impartially. If you are none of these you can be sure it will kill you too but there will be no special hurry.” Earnest Hemingway, A Farewell To Arms.

  6. #6
    Join Date
    Feb 2004
    Location
    Bangalore, India
    Posts
    250
    yes

    ... ;-)
    Cheers....

    baburajv

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •