Azure/azure-kusto-labs

Incorrect Ingestion CSV Mapping Script, columns are not aligned properly

garyleungyahoo opened this issue · 0 comments

The Ingestion CSV Mapping Script as shown below is not correct, columns are not aligned properly (eg. column "Source" should be column #12 instead of column #5):

.create table Storms ingestion csv mapping 'Storms_CSV_Mapping' '[{"Name":"StartTime","datatype":"datetime","Ordinal":0}, {"Name":"EndTime","datatype":"datetime","Ordinal":1},{"Name":"EventId","datatype":"int","Ordinal":2},{"Name":"State","datatype":"string","Ordinal":3},{"Name":"EventType","datatype":"string","Ordinal":4},{"Name":"Source","datatype":"string","Ordinal":5}]'

The correct Ingestion CSV Mapping Script should be:

.create table Storms ingestion csv mapping 'Storms_CSV_Mapping' '[{"Name":"StartTime","datatype":"datetime","Ordinal":0}, {"Name":"EndTime","datatype":"datetime","Ordinal":1},{"Name":"EventId","datatype":"int","Ordinal":3},{"Name":"State","datatype":"string","Ordinal":4},{"Name":"EventType","datatype":"string","Ordinal":5},{"Name":"Source","datatype":"string","Ordinal":12}]'