When I pull date/time columns from SQL using MS Query, the values are placed
in Excel as date/time. Therefore, I wonder if the dates in your SQL system
are stored as "YYYYMMDD" integers and not as dates. You can check this by
viewing the data in the query editor. If it shows up as "YYYYMMDD" then it's
not date/time data. Alternately, in the Query editor under the File menu is
an option for Table definition. If you check there you'll be able to see if
the column is date/time.



"aldsv" wrote:

>
> I use Excel Query Wizard to connect to a SQL server to get data. I
> return an invoice date, but the date is stored as "YYYYMMDD" integer.
>
> Is there a way I can modify the query to recognize the date as a
> "MM/DD/YYYY" format? I know how to write formulas in Excel that will
> give me the result, but I want to do it in the Query, so I don't need
> formulas.
>
> Perhaps I can modify the SQL statement (I've never used SQL).
>
> Thanks-aldsv
>
>
> --
> aldsv
> ------------------------------------------------------------------------
> aldsv's Profile: http://www.excelforum.com/member.php...o&userid=20494
> View this thread: http://www.excelforum.com/showthread...hreadid=375184
>
>