Note: Revision history for this Document Management product continues in the Release Notes pages.

 

RPG2SQL Integrator is ready for V6R1/V7R1 of i5/OS, starting with version 1.50

1.58.0

2015-12-18

  • The minimum OS/400 compatibility is now V6R1

1.57

2014-04-17

Added field delimiter parameter to SQLExtRecDDS API.

  • Syntax: SQLExtRecDDS(INFILE : INLIB : %ADDR(FldDefArray): %ADDR(FldPtrArray): %ADDR(FldDefCount) : FldDelimiter)
        The new field is defined as 4096 long, varying and NOPASS. If not passed in it will default to a tilde (~). This will allow current programs to continue to work without need of recompiling.  This field should be same value as what is used in the SQL_SetSQLDelim API.

1.56

2013-12-11

Added SQL_Verify API to check a connection

  • Syntax: SQL_Verify(IP_Addr : Port : TimeOut)
      Where:
    • IP_Addr is IP address of PC connecting to in either dot format or name
    • Port is Port to check of PC connecting to (5 char)
    • TimeOut is time to wait in seconds (2 char)

Added ability to handle Unicode/Graphic fields to SQLExtRecDDS API

1.55

2013-06-24

Changed SQL_Quote to only trim trailing spaces not both leading and trailing spaces

1.54

2013-01-11

Removed XLS examples that used ODBC. SQTEST04 & SQTEST09 were removed

1.53

2009-06-11

Fixed problem with national language builds, that the source for the main service programs was being converted twice, so that the product would not work at all.

Changes to SQLXLSIMP command

  • Changed wording from spreadsheet to workbook or worksheet
  • Added 'From worksheet' parameter - default is *ACTIVE

Added SQLXLSEXP (Export PF to Worksheet) command. Parameters include:

  • input file
    • must exist and be either a physical file or single-format logical file
    • special values for library include *LIBL and *CURLIB
  • output workbook
    • name must be valid for the RPG2SQL PC component
    • will be created if it does not exist
  • input member
    • default is *FIRST
  • output worksheet - default is *ACTIVE, the
    • default is *ACTIVE, the sheet that was was open when the workbook was last saved
    • will be added if not found
    • add/replace option included
      • default is *REPLACE
  • header
    • default is *COLHDG, which puts newlines between the parts of a column heading
    • other values are *NONE, *TEST, and *NAME
  • message logging - if there are any errors or warnings, they are sent to the job log; a final message is also sent to QSYSOPR; messages can be found in message file RPSMSGF in RJSRPGSQL. Diagnostic messages include:
    • NULL found
    • too many digits
    • too many characters
    • too many fields requested
    • too many rows requested
    • new workbook/worksheet created/added
  • host - name or address of PC where RPG2SQL PC component is running - special value is *CURRENT, which will be converted to the IP address of the PC on which the terminal emulation is running (does not work in a batch job)
  • first record (not RRN)
    • default is *FIRST
  • last record (not RRN)
    • default is *LAST
  • first field (by number)
    • default is *FIRST
  • last field
  • default is *LAST

1.52

2008-09-18

Fixed problem with commas in row/column values in XLS functions. This was a problem for customers in countries that use the comma as the decimal point.

1.51

2008-04-20

Updated SQL_GetParm to make sure that if there is a '199 EOF' present in the data buffer it gets stripped out automatically.

This update requires V1.0.57 or above of RPG2SQL Integrator PC Component.V1.0.57 of the PC component also fixes a lockup issue when calling SQL_GetParm.

1.50

2008-01-23

Updated SQL_GetFldNum and SQL_GetFldNumB functions to handle rounding appropriately. There were some cases where numbers that ended in whole number decimal values were rounding into fractional values when converted to 30,9. The new numeric conversion routine should resolve this issue.

Example of rounding error:

  • Value of 37294640.90 ~ Rounding to 37294640.899999999
  • Value of 10005654.36 ~ Rounding to 10005654.35999999

NOTE: Minimum OS/400 release is V5R1.

1.49

2007-06-26

Fixed problem with SQLXLSIMP that it truncated text in cells to 1024 characters. Maximum length is now around 4096 characters.

1.48

2006-09-08

Fixed problem with SQLXLSIMP that it said a number in cell A1 had non-numeric data.

1.47

2006-03-23

Finished SQLXLSIMP (Import Spreadsheet to PF) command. - message logging - if there are any errors or warnings, they are sent to the job log; a final message is also sent to QSYSOPR; messages can be found in message file RPSMSGF in RJSRPGSQL.

Diagnostic messages include:

  • row skipped due to unexpected error
  • row skipped for blank row
  • row defaulted for blank row
  • numeric overflow
  • text truncated
  • invalid characters in number
  • invalid date/time/timestamp
  • import error (escape message)

Added blank row handling - options are *SKIP (default) and *DFT - message logged in either case that identifies the row in the worksheet that was empty - more data type supported - binary, date, time, timestamp, and floating point - numbers with more decimals than the PF field has are truncated without comment

Fixed SQL_TCPMultBuff() so that it gets the entire buffer from the socket. Added SQL_TCPMultBuff() to all samples.

1.46

2006-02-02

Added XLS_SetDelimRc2 and XLS_GetDelimRc2, to get and set delimited buffer with 30,000-byte buffers.

Added XLS_RowColCount to retrieve row and column info from spreadsheet. Main use is to get number of rows in spreadsheet. Can also be used to get used range. Added SQLXLSIMP (Import Spreadsheet to PF) command. Parameters include: - workbook name - must be visible to the RPG2SQL PC component - output file - must exist and have field layout that matches spreadsheet - special values for library include *LIBL and *CURLIB - output member - mamber name and add/replace option - if member does not exist, it will be created - header rows - number of rows in header of spreadsheet - will not be included - error report - whether to report errors or warnings - not yet implemented - host - name or address of PC where RPG2SQL PC component is running - special value is *CURRENT, which will be converted to the IP address of the PC on which the terminal emulation is running (does not work in a batch job) At this time only character, zoned, and packed data types are supported. Empty cells will be converted to default values in the physical file. (Requires PC Component 1.0.47.)

1.45

2005-08-29

Changed SQL_GetDelimFld, SQL_GetDelimFlt, and SQL_GetDelimRcd to return T4096String instead of TString. Added more field type constants to RPGSQLH for use with SQL_GetDelimFlt.

1.44

2005-07-21

Added SQL_TCPTrace function for tracing TCP communications to file RPGSQLLOG.

SQL_TCPTrace(1) enables logging.
SQL_TCPTrace(0) disables logging. (Default)

Added SQL_TCPMultBuff function for attempting to read multiple data buffers when using SQL_MoveFirsBuf, SQL_MoveNextBuf, SQL_MoveLastBuf, & SQL_MoveprevBuf.

SQL_TCPMultBuff(1) enables multibuffer.

SQL_TCPMultBuff(0) disables. (Default) Either function must be called before the SQL_Connect function. Note: Requires PC component V1.0.42 or above.

1.43

2005-05-05

Added TCP_GetIPFromHost function, so that a fully-qualified domain name can be used, not just a dotted IP address. If a dotted IP address is passed in, it is left as is. The return values of TCP_GetIPFromHost are 0 if was successful, -11 if the fully-qualified domain name could not be found, and -12 if the 4-byte IP address could not be converted to dotted IP format.

The samples were changed to use TCP_GetIPFromHost in order to get the dotted IP address used to connect. COBOL samples were changed to use service program RPGSQL01R instead of RPGSQL02R, which does not have the newest features, including the Excel functions. The examples show how to use underscores in the procedure names, as well as variable-length character and binary parameters. COBOL copybooks RPGSQL1CB (for working storage) & RPGSQL2CB (some utility functions) were created. Build programs and COBOL programs were created in addition to the sample command and processing program.

1.42

2005-01-24

Change service programs RPGSQL01R, RPGSQL02R, and RPGDDS01R so that they will have the same signature from one version of the product to the next. Customers who use these service programs will not need to recompile their programs after this version, unless they use new functions.

1.40

2004-11-18

Added RPGDDS01R service program to binding directory so SQTEST25R and other samples will compile that use the DDS buffer service program. Also fixed SQTEST25R so that it will compile correctly. It was referring to SQL_ExtDDS* functions that have been renamed to SQLExtDDS.

1.39

2004-09-30

Added XLS_GETDELIMREC function to retrieve the contents of a spreadsheet row into a delimited record buffer. See sample SQTEST29 for example usage. Requires RPG2SQL PC Server V1.0.36 or above.

Extended data buffer from 256 to 4096 for SQL_GetFldChrb and SQL_GetFldChr buffer retrieval functions.Resolved lockup issues on PC component when using SQL_GetDelimRcd function to retreive delimited values from a record buffer when tilde was used as a delimiter. Requires RPG2SQL PC Server V1.0.36 or above.

1.38

2004-09-14

Added SQL_SetSQLDelim function for determining what value to use for delimiter. A tilde (~) is used as the default delimiter. A multiple character delimiter can be specified if desired. Requires RPG2SQL PC Server V1.0.34 or above.

Added SQLSetSQLDelim function to COBOL service program. This is the COBOL equivalent of SQL_SetSQLDelim. Added SQLNonBlocking function to COBOL service program. This is the COBOL equivalent of SQL_NonBlocking.

1.37

2004-09-08

Insure that internal data buffer gets cleared before doing buffered read operations. This was causing problems when customers actually wanted to save and parse the returned record data in their own programs instead of using the RPG2SQL field parsing functions.

1.36

2004-08-21

Major internal library enhancement. Added the ability to use non-blocking IP connections so that all SQL TCP/IP connections to the PC server can be set to be timed out after a selected number of seconds. Blocking connections are still the default so the SQL_NonBlocking function must be called before running the SQL_Connect function if non-blocking TCP/IP connections are desired. If 0 is passed for the timeout valuem the timeout value is defaulted to 60 seconds.

1.35

2004-07-19

Fixed problem with SQL timeout truncating timeout values, thus causing SQL queries to prematurely timeout.

1.34

2004-05-22

Added fully qualified library names to service programs bound to service programs RPGDDS01R and RPGSQL02R.

1.33

2004-04-19

Added API'S for reading a binary PC file by buffer.

  • SQL_PCFileOpenB - Open PC file for binary read access.
  • SQL_PCFileClose - Close PC file.
  • SQL_PCFileGetB - Read next 2KB buffer from the opened PC file.
  • SQL_PCFileSize - Returns size in bytes of PC file.

Added binding directory as well as H spec to header of all sample programs. This will eliminate the need to use the special B CL programs to generate an RPG2SQL RPG program. All samples can now simply be compiled with option 14. in PDM. Binding directory name: RJSRPGSQL in library RJSRPGSQL.

1.32

2004-03-07

Added sample program to write records to Domino database via NotesSQL ODBC driver. Added sample program to read records from Domino database via NotesSQL ODBC driver.

1.31

2004-03-05

Added sample program to create a new account, address, contact and opportunity record via SalesLogix.

1.30

2004-02-10

Added sample program to write email recip record to WinSpool Email Report Server access database WSPESR32.MDB.

1.29

2004-01-29

Consolidated includes into RPGSQLH to avoid AS/400 SQL precompiler messages because the AS/400 SQL precompiler does not support nested copy include statements.

1.28

2004-01-26

Added SQL_MKDir function for creating directories on the PC server.

1.27

2004-01-18

Changed SCTEST05L to have the following check IF SQL_RTN <> 0 instead of IF SQL_RTN > 0 after the call to SQLEXTDDS. This will insure that we bail out if DDS for selected file is not retrieved correctly.

1.26

2003-12-05

Added functions so programs can now read an entire SQL record into a DDS defined data structure or record structure without having to return each field individually. This was added to a separate service program named: RPGDDS01R.

Functions added:

  • SQLExtDDS - Extract DDS field information from AS/400 File definition for use with SQLExtRecDDS.
  • SQLExtRecDDS - Extract record data returned from the delimited record buffer to the selected DDS record structure. This assumes that the field names are returned from the SQL query in the same relative field order as the DDS definition.

Ex: If customer number is the first field returned from the SQL query the customer field should be the first field defined in the DDS defined record structure.

Added COBOL sample to read SQL Server database and extract record data to DDS defined record via SQLExtRecDDS- SCTEST05.

Added initial RPG2Excel functionality.

1.25

2003-10-14

Added Subfile Inquiry Interactive Samples. SQTEST23 - Query Records from Name/Address. Table with MS Access Driver. SQTEST24 - Query Records from Titles Table in Microsoft SQL Server PUBS database.

1.24

2003-07-22

Added logic to service program and to the PC server component to handle multiple TCP/IP data packets being sent from the AS/400. Apparently the original data packet can potentially arrive as multiple packets to the PC server component, so the new logic will handle this scenario. Requires RPG2SQL PC Server V1.0.18 or above. Extended SQL_Quote buffer size from 2048 to 4096 bytes.

1.23

2003-07-15

Added COBOL sample to read SQL Server database SCTEST04

Fixed COBOL service program to correctly process returned dates in MM/DD/YY format returned by SQLGetFldDat2B.

1.22

2003-07-03

Added SQL_LastErrNum2 function to return last ADO error message as a numeric value. SQL_LastErrNum returns the error number as a string. Added support for calling stored procedures with parms and also allow the return of parms or recordsets from SP calls.

Functions added:

  • SQL_RunSP - Run SP with parms.
  • SQL_RunSPSelect - Run SP and rtn recordset.
  • SQL_AddParm - Add SP parm.SQL_GetParm - Read return SP parm.
  • SQL_ClearParms - Clear all SP parms.
  • SQL_DBCloseRS - Close recordset.

1.21

2003-06-24

Added SQL_RunSPBasic to allow users to call SQL stored procedures and check for a successful return code. Soon we will add the ability to call stored procedures that can return parameter values as well as recordsets when a stored procedure is run.

1.20

2003-06-09

Added SQL_Quote function to allow users to take a string with a single quote and make sure it gets padded to two single quotes before performing a data insert via SQL. Otherwise strings with single quotes will cause an insert or update failure.

1.19

2003-04-19

Added RPGSQL02R service program wrapper for allowing COBOL programmers to use the RPG2SQL functionality. Added initial COBOL sample programs SCTEST01 - SCTEST03 to source file SOURCE. Also added NAMEADDR2 file definition.

1.18

2003-04-07

Soft coded ASCII/EBCDIC translation tables so users can set the tables to match their own systems.

1.17

2003-04-01

Added SQL Server transaction control functions.

  • SQL_BeginTran - Begin transaction.
  • SQL_CommitTran - Commit transaction.
  • SQL_Rollback - Rollback transaction.

Added SQL Server samples:

  • SQTEST10 - Insert recs to SQL Server table.
  • SQTEST11 - Read Recs from SQL Server table and display to user.
  • SQTEST12 - Insert recs to SQL Server table using committment control. This program illustrates the use of the SQL_BeginTran, SQL_CommitTran and SQL_Rollback functions

1.16

2003-03-28

Created SQTEST09 sample to read PF and write all records to Excel spreadsheet.

1.15

2003-01-14

Added DOCPING utility command so users can PING TCP/IP host printers and systems.

1.14

2002-12-25

Added new PC file management routines. SQL_PCFileEmpty - Create empty PC file.

1.13

2002-12-16

Added new PC file management routines. SQL_PCFileRen - Renames PC file.

1.12

2002-12-13

Make sure service program adds the RJSRPGSQL library to the library list, so the access code checking does not fail on program PRDINFO4 not being found.

1.11

2002-12-12

Re-added license check and status message.

1.10

2002-12-12

Temporarily removed license check from RPG service program RPGSQL01R. V1.08 test version was not working correctly.

1.09

2002-12-08

Re-added license check and status message.

1.08

2002-12-08

Temporarily removed license check from RPG service program RPGSQL01R.

1.07

2002-12-08

Created SQL socket test program SQLSOCKET.

1.06

2002-12-08

Added SQLTEST10 sample to test reading a CSV file to a PF via SQL.

1.05

2002-11-25

Added NEW buffered database functions to read back the entire record buffer. This enhances performance when doing bulk record reads from a SQL server or access database.

  • SQL_MoveFirsBuf - Move to first record.
  • SQL_MoveNextBuf - Move to next record.
  • SQL_MovePrevBuf - Move to previous record.
  • SQL_MoveLastBuf - Move to last record.
  • SQL_GetFldChrB - Get character field from record buffer.
  • SQL_GetFldNumB - Get numeric field from record buffer.
  • SQL_GetFldDatB - Get date field from record buffer when already formatted in ISO format.

Added SQLTEST08 sample to read all records from the IRPGSQL.MDB table to file SQLTEST8PF in QTEMP. This tests the new buffered reading commands.

Added SQLTEST09 sample to test the new PC file management routines.

  • SQL_PCFileCopy - Copy PC file.
  • SQL_PCFileDel - Delete PC file.
  • SQL_PCFileExist - Does file exist ?

Created new buffered record retrieval function which uses the ADO GetString method to retrieve a delimited record.

  • SQL_GetStrRow - Retrieve next record in delimited string format.

Created function to convert MM/DD/YYYY dates into ISO format when a record is retrieved by the SQL_GetStrRow function.

  • SQL_GetFldDat2B - Get date field from record buffer when already formatted in ISO format.

Created SQLDATE1C to convert MM/DD/YYYY dates into ISO format.

1.04

2002-11-13

Added SQLTEST06 sample to create a new spreadsheet via ADO.

Added SQL_PCFileExist function to check if a PC file exists.

Added SQL_PCFileDel function to delete a PC file if it exists.

Added SQL_PCFileCopy function to copy a PC file to a selected destination PC file.

Added AS/400 access code checking.

Added SQLUPG command to upgrade settings to new library if installed.

1.03

2002-11-04

Added SQL_GetFldDat,SQL_GetFldNum and SQL_GetFldChr field retrieval function calls. Characters fields are returned the same as the SQL_GetField function. Dates are returned in *ISO timestamp format. Numeric fields are returned as packed 30,9.

1.02

2002-10-16

Changed command SQLTEST01 to call SQLTEST01C instead of directly calling SQLTEST01R.Changed command SQLTEST03 to call SQLTEST03C instead of directly calling SQLTEST03R.

1.01

2002-10-09

INITIAL DEVELOPMENT RELEASE


Still have questions? We can help. Submit a case to Technical Support.

Last Modified On: August 09, 2018