Example for a CSV File Import
The asset.csv file located in the temp directory contains the following values:
Assetname, AssetSerialNumber,AssetPrice
"First Computer", "SerialNumber1", 1000
"Second Computer", "SerialNumber2", 2000
"Third Computer", "SerialNumber3", 3000
The corresponding XML file used to load the assets in the repository would be:
<ImportName="ASSET"
Type="CSV"
ConnectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=c:\temp;Extended
Properties='text;HDR=Yes;FMT=CSVDelimited'"
Query="select * from [asset.csv]">
<LogName="NewLog"Output="file"Loglevel="debug"filename="[IMPORT
NAME].log.txt"
</Log>
<ObjectName="asset"Type="asset"Output="assetoutid"Update="True"Create="True">
<Property
Type="shortdescription"
Name="Description"
Value="AssetName"
ValueType="FieldValue"
UseForMatching="false">
</Property>
<Property
Type="serialnumber"
Name="Serial Number"
Value="AssetSerialNumber"
ValueType="FieldValue"
UseForMatching="true">
</Property>
<Property
Type="purchaseprice"
Name="Purchase Price"
Value="AssetPrice"
ValueType="FixedValue"
UseForMatching="false">
</Property>
</Object>
</Import>
FlexNet Manager Suite (On-Premises)
2024 R2