ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Number of members via DDM

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

  • Number of members via DDM

    Hello everyone!
    Is there a way to find out if a member is in a file when the file is only accessed via DDM? Tried it through the CHKOBJ command, but got an error that to check the member, the object must be a database file.

  • #2
    One way might be to execute a copy file command against the DDM file member and if it errors out, the member doesn't exist:

    CPYF FROMFILE(ddmfile) TOFILE(QTEMP/TEMP) FROMMBR(ddmmember) MBROPT(*REPLACE) CRTFILE(*YES) NBRRCDS(1)
    MONMSG CPF2817

    Comment


    • #3
      Try SBMRMTCMD CHKOBJ through the same DDM file

      Comment


      • #4
        SBMRTMCMD... I should have guessed myself...
        Dennis See, thank you very much !!!

        Comment

        Working...
        X