company logo

PropertyHandle :: OpenExtern - Open property handle for external file

Property handles for external files are opened usually via predefined extents. In many cases, it is, however, more comfortable accessing incoming data directly without defining structure and extent in a dictionary.

Binary and ASCII files with different format can be accessed via property handle. When the file type is not defined in the extension, it must be passed explicitly as file type.

Since some external file types are not self describing, the file schema can be passed via a separate definition file. The definition file format need not to correspond to the file format, e.g. one may provide an ODL definition for a CSV file.

CSV or ESDF support file schema definition in the first line. The default headline for CSV files is a sufficient file schema definition in many cases. This does not work for binary files or OXML files, which require a separate definition. OIF supports built-in definitions as well.

Return value:  Success ( logical  )

Implementation details

  1. - internal feature
    logical PropertyHandle  :: OpenExtern ( DBObjectHandle &object_handle, NPath &cpath, NPath &def_file, NString &file_type, PIACC accopt, logical headline_opt, StringCoding sc_type )
    • object_handle - Database Object handle

      This is a pointer to an opened Database Object handle.

    • cpath - Complete file or directory path
    • def_file - Definition file
    • file_type - File type
    • accopt - Access mode
    • headline_opt - - internal feature
    • sc_type - - internal feature
  2. to list
  3. - internal feature
    logical PropertyHandle  :: OpenExtern ( DBObjectHandle &object_handle, NString &ntext, NPath &def_file, NString &file_type, PIACC accopt )
    • object_handle - Database Object handle

      This is a pointer to an opened Database Object handle.

    • ntext - Text string

      The text string contains text with any kind of character encoding.

    • def_file - Definition file
    • file_type - File type
    • accopt - Access mode
  4. to list