Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Day,Month,Year Concatenation Error

  1. #1
    Junior Member
    Join Date
    Dec 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Day,Month,Year Concatenation Error

    Hi Everyone,
    Iam getting the day value from one combobox,month value from another combobox and year value from textfiled.I have concat all three values and i passed the value to the MySQL Database .The error is

    com.mysql.jdbc.MysqlDataTruncation: Data truncation:

    Incorrect datetime value: '2010-Jan-21' for column 'dateOfAnn' at row 1d the value to the MySQL Database.


  2. #2
    Super Moderator Json's Avatar
    Join Date
    Jul 2009
    Location
    Warrington, United Kingdom
    Posts
    1,274
    My Mood
    Happy
    Thanks
    70
    Thanked 156 Times in 152 Posts

    Default Re: Day,Month,Year Concatenation Error

    Its probably because the value you pass in isnt a datetime value, its just a date.

    // Json

Similar Threads

  1. how do i get only the workig days for a certain month
    By anonimus83 in forum Algorithms & Recursion
    Replies: 2
    Last Post: January 11th, 2010, 10:13 AM