hey guys. i have this DB table:
CREATE TABLE public.sales_orders (
id serial4 NOT NULL,
customerid int4 NULL,
amount int4 NULL,
status varchar(30) NULL,
order_time int4 NULL,
order_name varchar(255) NULL,
product varchar(255) NULL,
product_id varchar(30) NULL,
amount_paid int4 NULL,
pay_time int4 NULL,
order_data text NULL,
ref1 int4 NULL,
payment_data text NULL,
ref2 varchar(255) NULL
);
and i get this error:
ERROR: value too long for type character varying(10).
The thing is that theres no column that has data type varchar(10). Im getting error here:
SalesOrder salesOrder = new SalesOrder();
salesOrder.setCustomerId(Long.valueOf(paymentInformationRequest.getClientId()));
salesOrder.setTransactionId(paymentInformationRequest.getTransactionId());
salesOrder.setAmount(paymentInformationRequest.getAmount().longValue());
salesOrder.setStatus("NEW");
salesOrder.setOrderTime(System.currentTimeMillis()/1000);
salesOrder.setOrderName("Pay Balance");
salesOrder.setProduct("Pay Balance");
salesOrder.setProductId("BALANCE SO");
salesOrder.setAmountPaid(paymentInformationRequest.getAmount().longValue());
salesOrder.setPayTime(System.currentTimeMillis()/1000);
salesOrder.setPaymentData(paymentData);
salesOrdersRepository.save(salesOrder)
can smb help me out debug this thing? I dont understand whats wrong