Results 1 to 2 of 2
  1. #1
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    Alzano Lombardo, Italy
    Posts
    1,483
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Query doesn't update time part of a Date/Time fiel (2003)

    Found the solution:
    UPDATE tblFilesFromFolder SET DateChecked = Format(DateSerial(Year([datechecked])+1,Month([datechecked]),Day([datechecked])),"dd/mm/yyyy") & " " & Format([datechecked],"hh:nn:ss")
    WHERE Year([DateChecked])=[forms]![fdlgselectfolder]![text9]

  2. #2
    Bronze Lounger
    Join Date
    Jan 2001
    Location
    Alzano Lombardo, Italy
    Posts
    1,483
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Query doesn't update time part of a Date/Time fiel (2003)

    I'm trying use the update query below to increase by one the year part of the DateChecked field in the tblFilesFromFolder table of the attached mdb.
    The date part of the field is updated correctly but how come the results of the update lack the time part in spite of it being specified in the format function?

    UPDATE tblFilesFromFolder SET DateChecked = Format(DateSerial(Year([datechecked])+1,Month([datechecked]),Day([datechecked])),"dd/mm/yyyy hh:nn:ss")
    WHERE Year(DateChecked)=[forms]![fdlgselectfolder]![text9]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •