I personally would follow your first hunch and fetch the row from DBI. Why? Databases are optimized for searching the tables, perl is not. SQL is more clear for searching. Just compare the other solutions with a simple SQL query:
select * from table where id=$rowid;.
in reply to Search an array ref of array refs
Another point, the databases mostly scale very well. If your table exceeds let's say more than 1000 items, perl will seriously slow down.
The performance penalty of the additional DBI call moreover probably is pretty small.
"We are not alone"(FZ)