[0] "_dateparsefailure"

I want to replace timestamp with my field timestamp. I have tried but getting error so kindly share solution for this problem.
"message" => "8/12/2020 0:00,jack,jazz,your recent attemt failed.,"9000.00 have been Debited on 02-08-2020, 13:15:55. For assistance call 627-627.

input{

    file{

        path => "x:/x/kuchkar_.csv"

        start_position => "beginning"

        sincedb_path => "Null"

    }

}

filter{

    csv{

        separator => ","

        columns => ["Date","name","Telco","LoginStatus","withdraw"]

    }

    date{

        match =>["message", "M/dd/yyyy hh:mm"]

        target => "@timestamp"

        add_field => {"month" => "%{+M}"}

    }
    stdout{

        codec => rubydebug

    }

}

I'm not sure what you are trying to do for month so removed that for now. But try the below to see if it gives you what you are looking for.

This should read your Date column in your CSV and set @timestamp with that value.

input {
    file {
        path => "x:/x/kuchkar_.csv"
        start_position => "beginning"
        sincedb_path => "NUL"
    }
}
filter {
    csv {
        separator => ","
        columns => ["Date","name","Telco","LoginStatus","withdraw"]
    }

    date {
        match =>["Date", "M/dd/yyyy hh:mm"]
    }
}
output {
    stdout { codec => rubydebug }
}

sir Still I am getting same error _dateparsefailure.

@timestamp" => 2021-03-05T17:55:47.977Z,
My date format => "Date" => "8/2/2020 0:00"
How I can replace Date format with @timestamp format.

Try match =>["Date", "M/dd/yyyy H:mm"]

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.