Pass sql date from talend to Rest Api

53 Views Asked by At

I want to send a post request to the rest API which includes an SQL date format, when I try to send the request with YYYY-MM-DD format, its showing bad request. How to properly send the data.

1

There are 1 best solutions below

0
Shyam Patel On

you can do something like this below,

 @PostMapping("/date")
    public void date(@RequestParam("date") Date date) {
        // ...
    }

Explanation: It will pass date from post request. you can also look at this documentation

I hope, it helps!