0% found this document useful (0 votes)
57 views1 page

How To Execute SQL On A System Without STRSQL: CRTSRCPF File (Sqltest) MBR (Sqltest) Text ('SQL Select Statement Test')

This document provides instructions for executing SQL statements on an AS/400 system without STRSQL by creating a physical source file containing the SQL statement, compiling it into a query with CRTQMQRY, and then running the query with STRQMQRY. The key steps are to create a physical file with the SQL statement, compile it into a query object, and then run the query object to execute the SQL statement without needing STRSQL installed on the system.

Uploaded by

Moulikpl
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
57 views1 page

How To Execute SQL On A System Without STRSQL: CRTSRCPF File (Sqltest) MBR (Sqltest) Text ('SQL Select Statement Test')

This document provides instructions for executing SQL statements on an AS/400 system without STRSQL by creating a physical source file containing the SQL statement, compiling it into a query with CRTQMQRY, and then running the query with STRQMQRY. The key steps are to create a physical file with the SQL statement, compile it into a query object, and then run the query object to execute the SQL statement without needing STRSQL installed on the system.

Uploaded by

Moulikpl
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

How to execute SQL on a system without STRSQL

Executing SQL statements from STRQMQRY (ie Interactive SQL - STRSQL is not on the AS/400)
From AS/400 command line create source physical file

CRTSRCPF FILE(SQLTEST) MBR(SQLTEST) TEXT('SQL SELECT STATEMENT TEST')

Using WRKMBRPDM edit file above and enter SQL statement


"YOUR SELECT STATEMENT HERE"

Enter CRTQMQRY referencing source file created in above steps

CRTQMQRY QMQRY(SQLTEST) SRCFILE(SQLTEST) SRCMBR(SQLTEST)

Enter STRQMQRY referencing QMQRY created in previous step. (Note:Run STRQMQRY with MAPICS
libraries (AMALIBx, AMFLIBy etc) in library list.

STRQMQRY QMQRY(SQLTEST)

You might also like