Migrating from IBM Informix 4gl to Genero BDL / 4GL programming topics |
Enhancement reference: BZ#19156
MAIN DEFINE fd1, fd2 INTEGER, v1,v2 VARCHAR(10) OPEN FILE fd1 FROM "/tmp/file1" OPTIONS (READ, FORMAT="CSV") OPEN FILE fd2 FROM "/tmp/file2" OPTIONS (WRITE, APPEND, CREATE, FORMAT="CSV") READ FROM fd1 INTO v1, v2 SEEK ON fd2 TO 0 FROM LAST INTO v1 WRITE TO fd2 USING v1, v2 CLOSE FILE fd1 CLOSE FILE fd2 END MAIN
Genero Business Development Language (BDL) implements file I/O support with the base.Channel built-in class. This class implements file access, but it can also open streams to subprocesses (i.e. pipes) and sockets.