Close the cursor for SQLite for 034 upgrade/downgrade on select

The list() is needed around the table select for SQLite upgrade/downgrade
to work.  This forces a cursor close and prevents database locked errors.

closes-bug: 1233329
Change-Id: I01aedf9d2743a86881c124c9690f10233d9966bc
Merge "Close the cursor for SQLite for 034 upgrade/downgrade on select" into milestone-proposed