-
-
Notifications
You must be signed in to change notification settings - Fork 134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Poji changed String 3/30/2021 to 3/30/21 #212
Comments
Let me understand clearly, you have a date column and you map it as String as follows:
and you get the value as "3/30/21" right? Normally It shouldn't be this way since it's of type String. Could you give me examples? |
Could you please share with me an excel file with those few examples? |
I need your sample excel file @vaquarkhan , otherwise I tried but couldn't produce this case for the date values like '3/30/2021' |
sample.xlsx |
Thanks @vaquarkhan , Now I see that there is a style in these columns and poi by itself gets their format index as 14 and theirs format string as 'm/d/yy'. You can debug all the cells of an excel file via https://github.com/ozlerhakan/poiji#debug-cells-formats. What you need to do is you can convert the format string of the format index via https://github.com/ozlerhakan/poiji#modify-cells-formats. You can use these steps:
and here it is: BTW when I opened it up on my local the columns look like this: |
Thanks let me check |
you can use 3.1.3 of Poiji @vaquarkhan , thank you for your contribution :) |
I have date 3/30/2021 which i am reading as String using Poji when its coming into POJO its coming like 3/30/21 .
Now issue is when i convert this 3/30/21 . to java.sql.date before store into MYSQL its coming like 0021-03-30.
How can i read full 3/30/2021 using poji ?
The text was updated successfully, but these errors were encountered: