Can someone help me to store the current system date in cassandra date column in format yyyy-mm-dd
using Java? I get exception while saving the java.sql.D
I had similar issues and As per Ashraful's answer, I have added below code in my model which resolved the issue.
Meta Data Model:
public class MetaData {
private String receive_date;
private String receive_hour;
**private com.datastax.driver.core.LocalDate error_date;**
}
In my service class, added below code.
final MetaData metaData = MetaData.builder()
.receive_date(row.getString("receive_date"))
.receive_hour(row.getString("receive_hour"))
.error_date(row.getDate("error_date"))
.build();