You can use annotations in a flatfile to extract data. The file name is required for the general tag. Hard-coded values are not permitted for the general tag attributes. For example, host_name="assetname" is not permitted. Enter the value parameter within brackets ([ ]). The value parameter represents the flatfile column index.
The following sample XML code illustrates how you can use annotations in a flatfile to extract data.
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <asset-converter xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <datasource type="flatfile">
<connection-properties>
<property filename="main" filepath="MainFile.txt" key="1" column_name="true"/> <property filename="system" filepath="SystemFile.txt" key="1" column_name="true"/>
</connection-properties> ...
<asset file="main" translator="ACBsFmt" version="1_0">
<general file="main">
<host_name value="[4]"/>
Note: 4 specifies it is mapped to the fourth column in the main file.
<default_hostname value="[4]"/> <default_address value="[3]"/> <default_mac value="[2]"/>
</general> ...
</asset> </asset-converter>
|
Copyright © 2013 CA.
All rights reserved.
|
|