0

当我运行代码然后从数据库中获取数据时,就会出现这个错误。

android.database.CursorWindowAllocationException: Cursor window allocation of 2048 kb  failed. # Open Cursors=741 (# cursors opened by this proc=741) run time error in titanium app

这基本上是一个数据库错误,但我没有解决方案。

4

1 回答 1

0

这是因为您没有关闭光标。

你可以按照这个:

 Cursor cursor = null;
  try {
      cursor = query();
  } catch (Exception e) {

  } finally {
      if (cursor != null)
         cursor.close();
   }
于 2013-11-19T08:06:36.497 回答