0

Im trying to fetch the data from DB which is updated from todays date to last 30days updated data(Timestamp)

Controller-class

@GetMapping("/getcodeByTs/createdTs")
public List<CodeSet> getCodeSetByCreatedTs(@RequestBody Timestamp createdTs){
    return codesetService.getCodeSetByCreatedTs(createdTs);
}

Service-layer

public List<CodeSet> getCodeSetByCreatedTs(Timestamp createdTs){
    return codeRepo.findCodeSetByCreatedTs(createdTs);
}

Repository

@Query(value="Select * from CODE_SET Where CREATED_TS = ? ",nativeQuery=true)
public List<CodeSet> findCodeSetByCreatedTs(Timestamp createdTs);

postman-output

Required request body is missing: public 
java.util.List<com.example.first.entity.CodeSet>
com.example.first.controller.CodeSetController.getCodeSetByCreatedTs(java.sql.Timestamp)

How can i fetch the data from DB

lane.maxwell
  • 5,002
  • 1
  • 20
  • 30
Rajesh
  • 1

0 Answers0