That too is how I understand the different explainations I have found on various websites and from what little I remember from
learning binary math years ago. (most of which I had forgotten and wish I had not and now am relearning!)
Here is an excerpt from an old post in their archives talking about Y2K problems and how one programmer was working with it:
"Yes, I know, but I need the same source code to be compilable for all these
versions. Currently, after doing a SYSDATE command, I add 693975 to the
result and it gives the right date. If dates in the year 2000+ get set up
as year 100, 101, etc., then I can simply continue doing this. If I set up
my 2.3b Enhanced systems to return a 4-digit year, I'll have to start
maintaining different source versions or modify the code after the SYSDATE
command to only add 693975 if the date returned is before 01/01/2000. I'm
hoping that the behavior I see with the year 100 is what is expected. Then
I can avoid modifying and deploying about 750 applications. "
In the old application that I am converting to Access db, it takes a two digit year ( 05 for 2005) if manually entering a date
or if the user just hits Enter, it enters the System Date (SYSDATE in Dataflex) which is the computer's current date. I posted
a request for more information on one of their current newsgroups that has helped me in the past. I am hoping that someone there
will be willing to share some more info on the DATE storage and a couple of other issues . As I told Cor in another post, so
far all I have got is offers to sell me an ODBC driver for Access to work with the Dataflex files($500.00) or
an offer to do the table conversions for me. (also quite expensive) Neither option is really what I want to do or can really
justify right now. Especially since my main hold up is the DATES . The rest of the problem (reading the Header structure for
Data Types and Field sizes) is about done. I have just had to do a search of several tables to see what addresses that contain
data info (not the actual data itself) are common to all the tables. I have had much better luck there. The rest of the data
besides the dates, is either in ASCII text or Decimal values that represent numbers, like, Number of Records, TIME (given in
seconds in the day) and several other bits of info. If I can find a way to get the dates correct, then I will have the biggest
part of the conversion proccess fixed.
Thanks so much for all your help. You and Cor have been a wealth of information.
james
"Jay B. Harlow [MVP - Outlook]" <(E-Mail Removed)> wrote in message news:(E-Mail Removed)...
> James,
> My understanding of BCD is that each hex digit (nibble) is its decimal digit.
>
> http://www.webopedia.com/TERM/B/BCD.html
>
> A byte that contains &H83 is bcd for 83 decimal.
>
> A byte that contains &H01 is bcd for 1 decimal.
>
> A byte that contains &H73 is bcd for 73 decimal.
>
> What I'm not sure about is what if anything they do with the sign (I would not expect a date to have a sign).
>
> Now when you have a sequence of bytes, endian makes a difference (which end of the sequence is most significant). My initial
> test was taking the first byte as most significant (&H83), it may be that the last byte (&H73) is most significant. In both
> cases the numbers seem way too large or way too small for the conversion you gave earlier.
>
> I'm curious on how Dataflex actually encodes their BCD.
>
> Hope this helps
> Jay