OPEN IFILE Examples
Example 1:
|
|
|
|
|
Logical file: |
EMPLMSTR |
|
Text file: |
Retrieved from ISAM key file |
|
ISAM file: |
EMPDATA.??? (.ISI under SUNDB86x or as defined in screen definition file under PLBCMP) |
|
Key length: |
Retrieved from ISAM key file |
|
Record length: |
Retrieved from ISAM key file |
|
Mode: |
SHARE (by default) |
Example 2:
|
|
|
|
|
Logical file: |
EMPLMSTR |
|
Text file: |
Retrieved from ISAM key file |
|
ISAM file: |
EMPSTR1.??? (.ISI under SUNDB86x or as defined in screen definition file under PLBCMP) |
|
Key length: |
Retrieved from ISAM key file |
|
Record length: |
Retrieved from ISAM key file |
|
Mode: |
EXCLUSIVE |
Example 3:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Logical file: |
IFILE |
|
ISAM file: |
c:\data\myfile.isi at the server |
|
Mode: |
SHARE |
|
Server address: |
www.server.net |
|
Server port: |
3934 |
Example 4:
|
|
|
|
|
|
|
|
|
|
|
|
|
Logical file: |
IFILE |
|
ISAM file: |
c:\payroll\myfile.isi at the server |
|
Mode: |
SHARE |
|
Server address: |
209.20.30.5 |
|
Server port: |
503 |
|
Mode: |
Shared |
View Examples
Example 1:
|
|
|
|
|
|
|
|
|
|
|
|
In this case, the index file 'myfile.isi' is being opened and a view named 'customer' is to be used. The 'customer' view name must exist in the 'sun_views' table found in the default schema used by the runtime.
Example 2:
|
|
|
|
|
|
|
|
|
|
|
|
In this case, the data file 'myfile.isi' is being opened and a view named 'customer' is to be used from the schema database referenced by the name 'xyzcompany'. The 'xyzcompany' name must exist in the default schema database being used by the runtime. The 'xyzcompany' reference identIFies a specIFic schema database that contains the 'customer' view to be used.
Example 3:
|
|
|
|
|
|
|
|
|
|
|
|
In this case, the behavior is the same as 'Case1' except the data file is located at a Data Manager. The schema database information is local to the client workstation.
Example 4:
|
|
|
|
|
|
|
|
|
|
|
|
In this case, the schema database information is retrieved from a Data Manager and used to access a data file opened local to a client workstation where the runtime is executing.
Example 5:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
In this case, both the schema database information and the data file is accessed at the Data Manager.
Example 6:
This example uses a DNS hostname 'www.mysundm.net' to logon to a Data Manager using the default 3934 port number. Also, the file name is being opened in a directory that exists on the Data Manager system.
|
|
|
|
|
|
|
|
|
|
|
|
|
Logical file: |
IFILE |
|
Text file: |
c:\temp\myfile.isi |
|
Server address: |
www.mysundm.net |
|
Server port: |
3934 |
|
Mode: |
SHARE |
![]() |