You are not logged in.
Pages: 1
How do you specify the field names in the DataDefinition when collecting data from a row in a CSV file?
Offline
This is how, I have it working to collecting data from a CSV file.
<Connector id="Input_File" type="CSV">
<Connection xsi:type="sxi:CSV">
<sxi:OutputFileName/>
<sxi:Delimiter>,</sxi:Delimiter>
<sxi:RetryDelay>30</sxi:RetryDelay>
</Connection>
<sxi:ReturnCodes>
<sxi:Success>
<sxi:Code>Success Code</sxi:Code>
</sxi:Success>
<sxi:RecoverableError>
<sxi:Code>Error Code</sxi:Code>
<sxi:Code>^.*No data collected for field.*$</sxi:Code>
</sxi:RecoverableError>
</sxi:ReturnCodes>
</Connector>
<SignalRegistry xsi:type="sxi:SigReg.CSV">
<sxi:ConnectorID>Input_File</sxi:ConnectorID>
<sxi:FolderPath>C:\CSVFILES\</sxi:FolderPath>
<sxi:ActionElement>ProcessCSV</sxi:ActionElement>
<sxi:FileName>^TestCSV_.*\.csv$</sxi:FileName>
<sxi:PollingDelay>10</sxi:PollingDelay>
<sxi:DeleteProcessed>yes</sxi:DeleteProcessed>
<sxi:ReadHeaders>no</sxi:ReadHeaders>
</SignalRegistry>
<Action name="ProcessCSV">
<Mappings>
<Collect dataDefinition="Read_Input_csv" connectorId="Input_File" source="C:\CSVFILES\" lookupField="na" lookupValue="na" />
</Mappings>
</Action>
<sxi:DataDefinition name="Read_Input_csv">
<sxi:Fields>
<sxi:Field name="0">
<sxi:OutputField datatype="string">TabelName1</sxi:OutputField>
</sxi:Field>
<sxi:Field name="2">
<sxi:OutputField datatype="string">TabelName2</sxi:OutputField>
</sxi:Field>
<sxi:Field name="3">
<sxi:OutputField datatype="string">TabelName3</sxi:OutputField>
</sxi:Field>
........
</sxi:Fields>
</sxi:DataDefinition>
Last edited by StephanB (16-08-2020 18:55:27)
Offline
Pages: 1