In SD library, a variable is used to represent either an SDS or a dimension scale. A variable is a structure that has a name, spatial information (rank and dimension sizes), and other related information. The variable.s name is that of the SDS or the dimension and rank is that of the SDS or always 1 for the dimension. When a dimension is assigned with an attribute, or is written with dimension scale, the library will .promote. the dimension to a variable record and store the additional information in the variable, referred to as dimension variable. This promoting process is transparent to the user. A user still accesses a dimension's data and attributes via SD interface routines that were designed for accessing dimensions. Since a dimension scale is stored in the same type of HDF object as an SDS, there is no difference between them from the HDF library's point of view. A dimension variable is simply a special case of the more general SDS variable. The dimension of a dimension variable always has rank 1 and the same name as the variable.s. One might see the two types of variables outputted from hdp, for example. Currently, the library is facing with two limitations regarding dimension variables and SDS variables. First, there is no distinction between the two types of variables. Second, the library searches the variable list for a dimension variable using the dimension.s name. In HDF, names are not unique among variables, although they are in netCDF. When a dimension.s variable is searched for in the variable list, it will be .found. as soon as a variable of the same name is reached, although, this could be an SDS instead. Thus, naming a dimension of an SDS the same as the SDS. name will result in loss of data. Subsequent writes, such as SDsetdimscale, will overwrite the data of the SDS, if it has already been written, and might change the SDS. datatype and other information. Referring only to SDSs that have a dimension of the same name, the current status is if an SDS that was created prior to hdf4 version??? (Aug 2005,) it is likely lost unless the same name dimension was never written. If an SDS that was created after version and was multi-dimensional, it is likely that the SDS is saved from the described problem. Unfortunately, it is not the same for one-dimensional SDS. A fix was applied in Aug 2005 helped reducing the chance of an SDS variable being confused as a dimension variable. However, the more likely case, one-dimensional SDS having the same name as the SDS, was still at large. A fix will be provided so that future created data files will not suffer from these limitations.