% Set con = Server.CreateObject("ADODB.Connection") con.Open connectionString Set rs = Server.CreateObject("ADODB.RecordSet") sql = "SELECT count(*) tmpCount from cityState" rs.Open sql,con if not rs.EOF then tmpCount = rs("tmpCount") else tmpCount = 0 end if rs.Close arrCount = int(tmpCount) if (arrCount > 0) then redim arrState(arrCount) end if sql = "SELECT distinct(state) as state from cityState order by state asc" rs.Open sql,con stateCtr = 0 while not rs.EOF stateCtr = stateCtr + 1 arrState(stateCtr) = rs("state") 'arrStateAbbr(stateCtr) = rs("stateAbbr") rs.MoveNext wend rs.Close con.Close %>