Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default how to export data into query

how do you export dates into a query
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 903
Default how to export data into query

Excel dates are stored as numbers from a reference point,
either you need to adjust the number by subtracting (or adding) a constant;
otherwise, if it is looking for a text date with slashes or hyphens then
you would have to format another cell as text
=TEXT(cellwithdate, "yyyy-mm-dd")
in VBA code it would be something like
strDate = FORMAT(datevariable,"yyyy-mm-dd")
strDate = Format(Date, "yyyy-mm-dd")
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"tires85" wrote ...
how do you export dates into a query



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5
Default how to export data into query

Thanks very much,
I will try this.

"David McRitchie" wrote:

Excel dates are stored as numbers from a reference point,
either you need to adjust the number by subtracting (or adding) a constant;
otherwise, if it is looking for a text date with slashes or hyphens then
you would have to format another cell as text
=TEXT(cellwithdate, "yyyy-mm-dd")
in VBA code it would be something like
strDate = FORMAT(datevariable,"yyyy-mm-dd")
strDate = Format(Date, "yyyy-mm-dd")
---
HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

"tires85" wrote ...
how do you export dates into a query




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Macro question Chris Excel Worksheet Functions 12 July 7th 06 01:23 AM
Inputting data to one worksheet for it effect another daedalus1 Excel Discussion (Misc queries) 1 June 25th 06 04:39 PM
From several workbooks onto one excel worksheet steve Excel Discussion (Misc queries) 6 December 1st 05 08:03 AM
Sort pages? David Excel Discussion (Misc queries) 15 May 13th 05 11:33 PM
Pulling data from 1 sheet to another Dave1155 Excel Worksheet Functions 1 January 12th 05 05:55 PM


All times are GMT +1. The time now is 02:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"