BOI Software Entwicklung und Vertrieb GmbH

Phone: +43 (0) 732 / 736423 - 0

Spazgasse 4

Email: office@boi.at

4040 Linz, Austria

www.boi.at

Copy and Move using Utility TABN05

Copy and Move using Utility TABN05

TABEX/4 offers functions for copying and moving of table data between TABEX tables, tables from relational databases, sequential databases, VSAM files and flat files. These copy and move functions can either be executed in batch or as menu items in the table manager. Conversion functions can be used to offer the data in varying formats.

TABEX/4 offers the option to save tables in the same databases or to overwrite data of distributed databases in the network (local databases on distributed computers or remote databases).

The TABEX/4 copy and move operations are performed using the utility TABN05.

The commands INPUT, OUTPUT, DATTRAN, FLDTRAN, INCLUDE, EXCLUDE and TRANSFER are used for this purpose.

  • INPUT defines the data source: this can be a sequential file, a TABEX table or a table from a relational database.

  • OUTPUT defines the data target. Also this can be a sequential file, a TABEX table or a table from a relational database. So all combinations of data sources and data targets are available for copying.

  • DATTRAN and FLDTRAN define the fields and sequence of the fields which are transferred to the data target.

  • Rows can be restricted so that only selected rows are transferred. For these restrictions the commands INCLUDE and EXCLUDE are used.

  • TRANSFER executes the data transfer.

Another option is to export data from tables into a sequential CSV file using the command EXPORT or to import data from a sequential CSV file into a table using the command IMPORT. In this case there are two options: Overwrite the data of the data target or add the data to the data target.

Example 1: Transfer of a sequential file to a single version table

IN,,F,,''TEST.INPUT.FILE1'',SHR
- Output file = single version TABEX table
OUT,,T,,,,,TESTTAB1,00000000
- Execute transfer
TRANSFER

 

Example 2: Transfer of a TABEX table to a DB2 table

- Input file = TABEX table
IN,,T,,,,,TESTTAB2
- Create DB2 connection
DB2OPEN,TABEX3,DSNA
- Output file = DB2 table
OUT,,D,,BOI.DB2TEST1
- Execute transfer
TRANSFER

 

Example 3: Transfer of data from the TABEX database TABVSAM to a DB2 database

- activate TABEX database
db=tabvsam
- Connect to relational database
sqlopen,dsn=db2win
- generate temporary view for using as input file
tempview,tmpv
select * from pl1test where index(Name,'Meyer ') > 0
- specify input and output files
INPUT,,T,,,,,tmpv,*TVW
OUTPUT,ADD,D,,boi.sqltest
- execute transfer
TRANSFER

 

Example 4: Transfer of data from a DB2 database to a sequential file TABOUT

- activate TABEX database
db=tabvsam
- assign output file (Windows)
setpar,1
NOALIAS DIO VAR 300 CRLF NOLEN A2E UNB
free,tabout
alloc,tabout,T:\.txt,%PAR01
- Connect to relational database
sqlopen,dsn=db2win
- specify input and output files
INPUT,,D,45,boi.sqltest,,,pl1test,99999999
output,,V,300
- alle rows having 010040 <= personalnumber <= 010070, with
- a salary not less than 5000
INCLUDE,personalnumber,GL,010040,010070
exclude,salary,<,5000
- definition of the output:
- field personalnumber in output position 1
dattran,personalnumber,,,,1
- constant '->' at output position 7
dattran,->,2,*C,,7,2,CH
- field salary converted to character at output position 9
dattran,salary,,,,9,10,CH
- constant '->' at output position 19
dattran,->,2,*C,,19,2,CH
- field name at output position 21
dattran,name,,,,21
- execute TRANSFER
transfer

Migration Packages

BOI GmbH offers migration packages for the table management systems SPITAB, TABSYS and VTAS.

 

» Migrations Packages

Success Stories

AirPlus has been using TABEX for 20 years.

Now TABEX/4 JAVA APPLICATION ENGINE has additionally been launched for audit-proof logging of the business processes by Java applications.

 

» read this success story

» more success stories