CDO$HELP.HLB  —  CDO Commands, EXTRACT  Examples
    1.CDO> DEFINE RECORD FULL_NAME.
      cont> FIRST_NAME.
      cont> MIDDLE.
      cont> LAST_NAME.
      cont> END RECORD.
         .
         .
         .
      CDO> DEFINE RECORD HOME_ADDRESS.
      cont> STREET_ADDRESS.
      cont> CITY.
      cont> STATE.
      cont> POSTAL_CODE.
      cont> END RECORD.
         .
         .
         .
      CDO> DEFINE FIELD BADGE DATATYPE IS UNSIGNED LONGWORD SIZE IS 5 DIGITS.
      CDO> DEFINE RECORD EMPLOYEE_REC_ONE.
      cont> FULL_NAME.
      cont> HOME_ADDRESS.
      cont> BADGE.
      cont> END RECORD.

      This example shows the definition of records used in the
      following examples.

    2.CDO> EXTRACT RECORD EMPLOYEE_REC_ONE /LANGUAGE=CC

        struct employee_rec_one
        {
          struct   {
            char  first_name[20];     /* Text */
            char  middle;     /* Text */
            char  last_name[20];      /* Text */
          } full_name;
          struct   {
            char  street_address[30]; /* Text */
            char  city[20];   /* Text */
            char  state[2];   /* Text */
            unsigned long  postal_code;       /* Unsigned Longword */
          } home_address;
          unsigned long  badge;       /* Unsigned Longword */
        };

      This example shows the EXTRACT command specifying the
      /LANGUAGE=CC qualifier.

    3.CDO> EXTRACT RECORD EMPLOYEE_REC_ONE /LANGUAGE=CDO
      Define record CDDRTEST:[CDDR_TEST.userid.TEST_REP]MY_DIR.EMPLOYEE_REC_ONE
          .
          CDDRTEST:[CDDR_TEST.userid.TEST_REP]MY_DIR.FULL_NAME(1).
          CDDRTEST:[CDDR_TEST.userid.TEST_REP]MY_DIR.HOME_ADDRESS(1).
          CDDRTEST:[CDDR_TEST.userid.TEST_REP]MY_DIR.BADGE(1)
          .
      End record.

      This example shows the EXTRACT command specifying the default
      /LANGUAGE=CDO qualifier.
Close Help