Re: use of DBCENTURY
Posted in 1998
Topics: Performance & Tuning
''' ''''''''' ' ''''''' MIME ''''''' '' '''''''''' ''''''. ------=_NextPart_000_01BDAF45.97CADAA0 Content-Type: text/plain; charset=KOI8-R Content-Transfer-Encoding: 8bit Hi, Here attached is the information that might be helpful for you. Regards. Infodata <infodata@batelco.com.bh> '''''''' ' '''''' <6oeus7$hsf$1@news.xmission.com>... > > Hi all, > > I would appreciate some insight into the use of DBCENTURY variable. > > Do both the tool and the server require to support DBCENTURY, to use its > features, or is it sufficient for the server to only have this capability ? > > What are the values that can be assigned to this environment variable ? I > understand that it can be used to change the default century to the century > closest, before or after the current date. But what are the respective > settings for these ? > > Thanks in advance, > > Sandeep > > > ------=_NextPart_000_01BDAF45.97CADAA0 Content-Type: application/octet-stream; name="year2000.htm" Content-Transfer-Encoding: quoted-printable Content-Description: year2000.htm (Netscape Hypertext Document) Content-Disposition: attachment; filename="year2000.htm" <html> <TITLE> Year 2000 and Informix Products</TITLE> <HTML> <MAP NAME=3D"navbar"> <AREA SHAPE=3D"rect" HREF=3D"/" COORDS=3D"0,13 44,28"> <AREA SHAPE=3D"rect" HREF=3D"/searchorg/iaquery" COORDS=3D"44,13 89,28"> <AREA SHAPE=3D"rect" HREF=3D"/infmx-cgi/Webdriver?MIval=3Ddemos" = COORDS=3D"89,13 134,28"> <AREA SHAPE=3D"rect" HREF=3D"/informix/comments/q_a1.htm" = COORDS=3D"134,13 193,28"> </MAP> <BODY BACKGROUND=3D"/informix/solution/300b.jpg" BGCOLOR=3D"#FFFFFF" = TEXT=3D"#000000" LINK=3D"#008A00" VLINK=3D"#999999" ALINK=3D"#0000FF"> <TABLE BORDER=3D0 CELLSPACING=3D0 CELLPADDING=3D0 WIDTH=3D610> <TR WIDTH=3D100%> <TD WIDTH=3D191 VALIGN=3Dtop HEIGHT=3D100><IMG = SRC=3D"/informix/informix_logo_1.gif" BORDER=3D0></TD> <TD ALIGN=3Dright VALIGN=3Dtop HEIGHT=3D100><IMG = SRC=3D"/informix/02p_ban.gif" USEMAP=3D"#navbar" BORDER=3D0></TD> </TR> </TABLE> <!-- this is magic - dont touch!! --> <TABLE BORDER=3D0 CELLSPACING=3D0 CELLPADDING=3D0 WIDTH=3D610> <TR><TD></TD></TR> </TABLE> <!-- <IMG SRC=3D/informix/02_ban.gif> <TABLE> <TR><IMG SRC=3D/informix/sectiontitle.gif> <TD WIDTH=3D700> <TD> --> <TABLE BORDER=3D0 CELLSPACING=3D0 CELLPADDING=3D0 WIDTH=3D610> <TD WIDTH=3D60><IMG SRC=3D"/informix/clear_pixel.gif" WIDTH=3D60 = HEIGHT=3D1></TD><TD WIDTH=3D550> <HEAD> </HEAD> <H1>Year 2000 and Informix Products</H1> <P> In recognition of the challenges posed by the approach of the year 2000, Informix Software, Inc. has taken the steps necessary to provide year 2000 compliance in its products. This document describes those steps and other related considerations.<BR> <P> <H2>Year 2000 Compliance</H2> </B> <P> All Informix products are year 2000 compliant, meaning that the use or occurrence of the dates on or after January 1, 2000, will not adversely affect the performance of the Informix products with respect to four-digit date dependent data or the ability of such products to correctly create, store, process, and output information related to such date data. <BR> <P> However, there are some year 2000 issues which are not within the control of database software. Specifically, the manner in which an application is written to accept a date value and the habits of users entering dates into an application. Generally, year 2000 issues associated with these problems must be addressed at the application level. As described below, Informix has added a "DBCENTURY environment variable" feature to the Informix products listed in the table below which may help users provide year 2000 compliance in their existing applications without recoding. <p> For specific information on Informix's Client APIs, see the <A = HREF=3D"api2000.htm">Year 2000 support in Informix client API products</a> page. <P> <H2>DBCENTURY Feature</H2> </B> <P> The DBCENTURY environment variable is an indicator which controls how Informix sets the default century value for Date and Datetime datatypes when the user has not entered the full four digits for a year. DBCENTURY must be added to the login profile of a user on the client system, and is thereafter automatically applied to all Informix applications associated with that login id. No changes are required to the application code whatsoever to take advantage of this feature. If the DBCENTURY variable is not present, the Informix product will default the century value to the current century, which it obtains from the computer's system clock. If the DBCENTURY variable is present, it can be set to select a default date that is before, after, or closest to the computer's system clock. Informix anticipates that the latter setting will be the most generally applicable for the next several decades. <P> For example, if a user enters two years, '95 and '03, and the DBCENTURY variable for that user's login profile is set to default to the closest date, Informix will assign the years 1995 and 2003 to the two dates, respectively. If the DBCENTURY variable is not present in the user's login profile, the dates would default to 1995 and 1903, the current century. If the user enters the full four digits for the years, they will be accepted as entered, regardless of the DBCENTURY variable setting.<BR> <P> Obviously, if the user enters only two digits for the year, and the default century is incorrect, an error will occur. For example, if a user enters '03 as shorthand for 1903, and the DBCENTURY variable is set to default to the closest date, the Informix product would store 2003. Since very few applications deal with dates which are more than 50 years in the past or in the future, there should be little danger of such an error. However, since not all scenarios can be automated, the ultimate solution is for the users to be trained so as to enter the full four digits of a year which is either in a different century from the current date, or is more than 50 years earlier or later than the current date. If an application only allows a two-digit entry for the year, it may need to be recoded to allow the option of a four digit entry if the automatic settings do not encompass all of the dates that are going to be employed in the application.<BR> <BR> <H2>DB Century Support by Product and Release Version</H2> <BR> </B> <TABLE BORDER=3D"1"> @