Y2K Problem (SET EPOCH??) 
Author Message
 Y2K Problem (SET EPOCH??)

I have programs written in Clipper 5.2E that only handle 2 digit years.  I
know the SET EPOCH command will allow me to go into the new century, but
here is my problem.  The program accepts input from data disks generated by
other programs, these programs handle dates with only 2 digits also.  DBase
databases store a century in the database for each date even if you only
use 2 digits.  How will the program (using SET EPOCH) handle these century
digits in the imported databases.  Will it see it as 20th century or will
it automatically accept it as 21st century?  Any help would be appreciated
if you have any expeience in this matter.



Sun, 15 Oct 2000 03:00:00 GMT  
 Y2K Problem (SET EPOCH??)



Quote:
>I have programs written in Clipper 5.2E that only handle 2 digit years.  I
>know the SET EPOCH command will allow me to go into the new century, but
>here is my problem.  The program accepts input from data disks generated by
>other programs, these programs handle dates with only 2 digits also.  DBase
>databases store a century in the database for each date even if you only
>use 2 digits.  How will the program (using SET EPOCH) handle these century
>digits in the imported databases.  

If dBase stored it as 1920, and you import it with APPEND FROM, it
will import as 1920. You may have to add some correction logic in your
import routine.

Perhaps, rewrite the import routine to do it a record at a time, like
read a record into variables, adjust date offsets, write a record,
instead of APPEND FROM.

This is known as encapsulation. You shield all points of data entering
your system and intercept dates to correct them. You might also need
to modify output streams.

--

        Oasis WWW  http://www.iag.net/~philb/
 Oasis WWW Mirror  http://www.enterconnex.com/oasis/
         FTP Site  ftp://ftp.iag.net/pub/clipper

      Everything that is really great and inspiring is
      created by individuals who can labor in freedom.

                                     Albert Einstein



Mon, 16 Oct 2000 03:00:00 GMT  
 Y2K Problem (SET EPOCH??)

Quote:

> I have programs written in Clipper 5.2E that only handle 2 digit years.  I
> know the SET EPOCH command will allow me to go into the new century, but
> here is my problem.  The program accepts input from data disks generated by
> other programs, these programs handle dates with only 2 digits also.  DBase
> databases store a century in the database for each date even if you only
> use 2 digits.  How will the program (using SET EPOCH) handle these century
> digits in the imported databases.  Will it see it as 20th century or will
> it automatically accept it as 21st century?  Any help would be appreciated
> if you have any expeience in this matter.

Hello SCZM,

The .dbf file format will record the date fully as YYYYMMDD so 19 is
highly likely to be the first two digits provided by your old programs
that write to the floppies. A case of never being able to get black
coffee if the milk is already mixed with the coffee in the dispenser.

Solution is back at the original source of the data files. Fix that
first and then your set epoch and century will fall into line.

Best of luck,

Ross McKenzie
ValuSoft
Melbourne Australia



Mon, 16 Oct 2000 03:00:00 GMT  
 Y2K Problem (SET EPOCH??)

: I have programs written in Clipper 5.2E that only handle 2 digit years.  I
: know the SET EPOCH command will allow me to go into the new century, but

Why don't you use at the beginning of your program
SET DATE FORMAT TO YYYY/MM/DD?

--
         *** Learn Esperanto - the International Language! ***
One language for all           |      Unu por chiuj,
the second for everyone!       |     la dua por chiu!



Tue, 17 Oct 2000 03:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Y2K - set epoch

2. Y2K and SET EPOCH TO

3. The cost of using SET EPOCH

4. SET EPOCH

5. epoch setting

6. Valid clause and set epoch / century

7. set EPOCH to nnnn

8. SET EPOCH not the cause??

9. SET EPOCH Issue?

10. set epoch

11. Summer '87 SET EPOCH TO!!

12. need library for set epoch

 

 
Powered by phpBB® Forum Software