Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9071263
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T17:52:00+00:00 2026-06-16T17:52:00+00:00

Hello I have a Grails application which uses so far java.util.Date to store a

  • 0

Hello I have a Grails application which uses so far java.util.Date to store a timing value into a Microsoft SQL Server Database.

I load the date values form a .csv file with that format:

java.util.Date send_date = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS").parse(data[1]);

If I watch the var send_date with my debugger the field for milliseconds has the right value millis = 241

The variable send_date which is a java.util.Date type creates a Data Type = datetime column in my Database but then the value in the Database is 2007-10-04 10:10:53.240 This means the milliseconds are wrong. It always appears random, sometimes it is the right amount of milliseconds sometime +1 or -1.

Does anybody know a other data type which is compatible with my database, I already tried java.sql.Date but then I do not have a constructor to add this format "yyyy-MM-dd HH:mm:ss.SSS" If anybody knows how I can create another date object with this input format please let me know 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T17:52:01+00:00Added an answer on June 16, 2026 at 5:52 pm

    SQL Server’d DATETIME data type has a 3 ms resolution. If you need a higher resolution use the DATETIME2 data type. It has a 100 ns resolution.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hello I have an android application which has a service running. After 20 mins
Hello I have a bunch of text on my file which i display. I
Hello i have a problem with c# Arrays. I need a array to store
Hello I have an array $name[] that I am trying to insert into the
Hello I have developed a small menu bar in jsp which collects attribute of
I have a really annoying problem with a deployed Grails application on tomcat 7
How can you have a grails application as well as other servlets defined in
I have an application written in grails. I want to add a new domain
Hello I am using Grails 2.1 and I have a little problem I can't
hello i have a desktop application that communicate with a wcf service that i

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.