Results 1 to 4 of 4
  1. #1
    Join Date
    Aug 2012
    Posts
    1

    Unanswered: Cast function in DB2

    Hi All,

    I need to convert a VARCHAR to LONG datatype in db2.Kindly help me.

    query:
    SELECT (CAST (LOGINTRAILID AS LONG) AS NEWLOGINTRAILID) from tibsadmin.userloginaudittrail

    errorQL01204N "LONG" is an undefined name SQLSTATE=42704

  2. #2
    Join Date
    Oct 2009
    Location
    221B Baker St.
    Posts
    486
    Suggest you post this in the proper part of the forum. . . The DB2 part of the forum.

    Possibly a moderator will see this and re-locate it.

  3. #3
    Join Date
    Oct 2009
    Location
    221B Baker St.
    Posts
    486
    Also, you need to post which db2 release/fix level and operating system is being used.

  4. #4
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    Quote Originally Posted by Athif View Post

    I need to convert a VARCHAR to LONG datatype in db2.
    I suspect what you mean by LONG is indeed CLOB.
    ---
    "It does not work" is not a valid problem statement.

Posting Permissions

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