I am working with a following SQL table named "ticket"
. Now let's see the data types for the columns.
SQLColumns[conn,"ticket"]/.SQLColumn[{"ticket",a_},"DataTypeName"->b_,
"DataLength"->c_,"Default"->__,"Nullable"->__]:> a-> {b,c}
{"end_time_stamp" -> {"int8", 19}, "kms" -> {"varchar", 255}}
Now when I use SQLInsert
to enter the values in the columns I get no error.
SQLInsert[conn, "ticket", {"end_time_stamp", "kms"}, {20161102135641,"273-A"}]
However fetching the data from table shows wrong integer was inserted.
SQLSelect[conn, "ticket", "end_time_stamp", SQLColumn["kms"] =="273-A"]
{535656579}
where as we should get the integer 20161102135641
back. I have loaded the database driver using JDBCDrivers["PostgreSQL"]
.
Could not find much in the docs about this strange issue.