VMS Help  —  RDML72  Statements  STARTING_WITH, Examples  C Example
    #include <stdio.h>
    DATABASE PERS = FILENAME "PERSONNEL";

    main()
    {
    READY PERS;
    START_TRANSACTION READ_ONLY;

    FOR E IN EMPLOYEES CROSS D1 IN DEGREES OVER EMPLOYEE_ID
       WITH (UNIQUE D2 IN DEGREES WITH D2.EMPLOYEE_ID = E.EMPLOYEE_ID)
       AND D1.DEGREE_FIELD = "Arts"
       AND D1.COLLEGE_CODE = "STAN"
          printf ("%s\n", E.EMPLOYEE_ID);
    END_FOR;

    COMMIT;
    FINISH;
    }
Close Help