in reply to Oder of HASH ARRAYS

If you want the data in a specific order, then specify the order in the SELECT and ask for the result as an array:

SELECT field1, field2, etc. FROM...

Alternatively, SELECT * will return the data in the order the fields are stored in the table, but again, you need to ask for the results as an array rather than a hash. fetchrow_hashref() is not something I personally find terribly useful.