GET function

The GET function returns the data from the source adapter.

When you are not using a database/query file (.mdq), the –SOURCE and –STMT commands are mandatory unless there is a default data source specified for DB2® ODBC. For detailed information about DB2 ODBC, see the DB2 Universal Database for z/OS®: ODBC documentation.

Using GET with a database/query file

GET ("DB",
 "-MDQ mdq_file
  -DBNAME database_name
  -QUERY query_name|-STMT SQL_stmt
[-FILE [directory]]
[-VAR name=value...]
[-USER username]
[-PASSWORD password]
[-CCARD|-CSTMT [number]]
[-ROWCNT row_count]
[-AUDIT[G][+] [full_path]]
[{-TRACE|-TRACEERR}[+] [full_path]]")

Using GET without a database/query file

GET "DB",
"-DBTYPE ODBC 
 -STMT SQL_stmt
[-SOURCE datasource]
[-FILE [directory]]
[-USER username]
[-PASSWORD password]
[-ROWCNT row_count]
[-CCARD|-CSTMT [number]]
[-AUDIT[G][+] [full_path]]
[{-TRACE|-TRACEERR}[+] [full_path]]")