WASHINGTON POST: "3 Most-Used Fixes to Beat the Bug"greenspun.com : LUSENET : TimeBomb 2000 (Y2000) : One Thread
3 Most-Used Fixes to Beat the Bug
By Rajiv Chandrasekaran
Tuesday, January 4, 2000; Page E01
Computer programmers used a variety of methods to fix Y2K bugs. Here's a description of three of the most popular techniques:
* Expand two-digit years to four digits. The Y2K problem stemmed from the fact that many computers stored only the last two digits of a year, assuming that the first two would be 1 and 9. If not repaired, the machines would think the year 2000 -- or "00" -- is 1900, which could cause them to shut down or stop working properly. Software engineers combed through millions of lines of computer code to look for places where two-digit years were stored and reprogrammed them to handle four-digit years. (In computer speak, "YYMMDD" became "YYYYMMDD.") The approach ensures that the system will work until the year 9999, but it can be costly and labor-intensive because programmers also have to reformat data records. That's no small feat: A large bank, for instance, can have billions of records, such as a list of when certain checks cleared, that include dates that would need to be changed.
* Use a "window." This technique attempts to make a computer understand whether a two-digit year should be preceded by a "19" or a "20." The programmer chooses which years are in the 20th century and which are in the 21st by establishing a "window." A 30-year window, for instance, would have the program interpret the years "00" through "29" as 2000 to 2029, while years "30" through "99" still would have a 19 in front. The big advantage to this method is that data records do not have to be reformatted, but the approach isn't a panacea. Windowing still requires date-related calculations in programs to be modified, and if the software is still running 30 years from now, it will have to be repaired once again. Nevertheless, one analyst called it "one of the fastest and cheapest ways to fix the Y2K problem."
* Roll the clock back. Programmers rolled the internal clock on some computer systems back to 1972, because the days of the week match those of 2000 and both years are leap years. The method was commonly used in developing countries and small businesses that could not afford the costlier windowing or date-expansion techniques. But most experts advised against the approach unless absolutely necessary because interfaces with other systems could be affected and any reports generated by the software would be incorrect.
-- John Whitley (email@example.com), January 04, 2000
as far as the "yyyy"-weren't the programmers just setting themselves up for a y10k problem?
-- futureshock (firstname.lastname@example.org), January 04, 2000.