ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Insert in SQLRPGLE

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Insert in SQLRPGLE

    Hi All,

    I am trying to Insert records in SQLRPGLE using the below SQL:

    insert into File1
    (select * from QTEMP/TMP001)

    QTEMP/TMP001 is created using the below SQL:

    CREATE TABLE QTEMP/TMP001 as (SELECT * FROM File1)
    DEFINITION ONLY

    File 1 contains fields with datatype Z. When i execute the statement in STRSQL its working fine. But when i do the same in SQLRPGLE and compile it, it throws a compile time error saying its not compatible.

    I cant figure out the problem.

    Regards,
    Arunprasad

  • #2
    Re: Insert in SQLRPGLE

    Compile your program with option Commit *NONE

    Birgitta

    Comment


    • #3
      Re: Insert in SQLRPGLE

      Are you sure this is SQLRPGLE and not SQLRPG? What version of the OS are you on?
      Michael Catalani
      IS Director, eCommerce & Web Development
      Acceptance Insurance Corporation
      www.AcceptanceInsurance.com
      www.ProvatoSys.com

      Comment


      • #4
        Re: Insert in SQLRPGLE

        its SQLRPGLE micheal. but this query is now working fine. dont now how. i didnt do any change.

        Comment


        • #5
          Re: Insert in SQLRPGLE

          I love those

          I couldnt remember off the top of my head when the timestamp fields were allowed in rpgiv, but I was thinking that you were either compiling it with the wrong compiler. (either rpg or the rpgiv compiler specifying a target release that did not support the timestamp fields. )
          Michael Catalani
          IS Director, eCommerce & Web Development
          Acceptance Insurance Corporation
          www.AcceptanceInsurance.com
          www.ProvatoSys.com

          Comment

          Working...
          X