One way to create a view and cast the values to the different types.
We use this trick quite often in views to deal with implied 2 decimal
place values. For example 1.5 credits is stored as a short as 150
and is displayed in a view with :
cast(cast(credits,real) / 100.0,decimal(5,2))
Something like this might work for dates:
Create view MyView ( ViewDate, ViewTime )
as Select
cast(DBDate,Date,"YYYYMMDD"), /* syntax here may be wrong */
cast(DBTime,Time,"HHMMSS") /* check the ALLBASE manual */
from MySet;
The problem you will have is that MS Access(and MS SQL Server)
do not incorporate separate Date and Time data items, only a
DateTime data item.
There may be some trick you can use to combine your two
database fields into one DateTime view field. I don't know what that
trick would be right now but it might be worth a shot..
On 24 Mar 00, at 9:11, Gary Nolan wrote:
> Hi Folks,
>
> I am experimenting with ODBC/SE and have a dumb question. I have two fields
> in a TurboIMAGE database.
>
> DATE X 8 (yyyymmdd)
> TIME X 6 (hhmmss)
>
> How do I get ODBC - MS Access to understand that these are date and time
> fields? Access seems to only understand these fields only when the date has
> '/', and the time ':' in the data. I know I must be missing something
> simple. Any suggestions would be appreciated.
>
> Thanks
> Gary Nolan
> Sydney Steel Corporation
--=--=--
Bob Walker, Computer Centre -- [log in to unmask]
Capilano College, North Vancouver, BC, CANADA.
------
'No one is listening until you make a mistake.'
|