1

I have two tables. One was created in excel, Table1, the other is an attribute table associated with a shapefile, Table2.

Table1

Table2

I want to join Table1 and Table2 into a single table, using the day of the year. When I try and run the "Join Field" tool, Table3 contains all the information from Table1, but Table2's time values have all been changed to midnight. When I perform a temporary join, it works just fine. I tried turning Table1's 'Date' from a string to a date, so it would match Table2, but it didn't fix anything.Table3

  • If you export the shapefile that contains the temporary join result, are all the times still midnight? – Louis May 8 '17 at 19:14
  • Yes. I tried that and it unfortunately didn't work. – J.W. Powell May 8 '17 at 19:16
  • Have you tried converting the Excel table to dbf directly? If that worked you could run the join with the dbf. – johns May 8 '17 at 20:04
2

Date fields in Shapefiles (and DBF) do not store time, only dates. From Fundamentals of date fields:

for coverages and shapefiles, the time portion is truncated from the datetime value. For example, the datetime 2002-08-20 12:00:00 PM is stored in a coverage or shapefile as 2002-08-20.

If you want to store the time you'll need to convert to text first, or store the output in a File Geodatabase table or feature class.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.