From e59bb3078f62fb26cc5cbafd4e47857f467fa3c4 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Wed, 10 Jun 2009 08:22:00 +0000 Subject: [PATCH] Speed up large SELECT operations a bit --- chrome/content/zotero/xpcom/db.js | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/chrome/content/zotero/xpcom/db.js b/chrome/content/zotero/xpcom/db.js index 2eeab1ddd..8acee71ab 100644 --- a/chrome/content/zotero/xpcom/db.js +++ b/chrome/content/zotero/xpcom/db.js @@ -111,12 +111,18 @@ Zotero.DBConnection.prototype.query = function (sql,params) { var statement = this.getStatement(sql, params, true); - var dataset = new Array(); + // Get column names + var columns = []; + var numCols = statement.columnCount; + for (var i=0; i