Return-Path: X-Original-To: apmail-commons-issues-archive@minotaur.apache.org Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 44A1810208 for ; Wed, 16 Jul 2014 17:34:06 +0000 (UTC) Received: (qmail 71526 invoked by uid 500); 16 Jul 2014 17:34:06 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 71432 invoked by uid 500); 16 Jul 2014 17:34:05 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 71420 invoked by uid 99); 16 Jul 2014 17:34:05 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Jul 2014 17:34:05 +0000 Date: Wed, 16 Jul 2014 17:34:05 +0000 (UTC) From: "Benedikt Ritter (JIRA)" To: issues@commons.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (DBUTILS-110) ArrayHandler should return an empty array when handle has no rows MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DBUTILS-110?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Benedikt Ritter updated DBUTILS-110: ------------------------------------ Summary: ArrayHandler should return an empty array when handle has no rows (was: Inconsistent behaviour when handle has no rows) > ArrayHandler should return an empty array when handle has no rows > ----------------------------------------------------------------- > > Key: DBUTILS-110 > URL: https://issues.apache.org/jira/browse/DBUTILS-110 > Project: Commons DbUtils > Issue Type: Improvement > Affects Versions: 2.0 > Reporter: Sebb > Assignee: Benedikt Ritter > Fix For: 1.6 > > > ArrayHandler#handle returns null if there are no rows. > However ArrayListHandler#handle returns an empty list, as do all the other implementations that return a collection. > It would be more consistent if ArrayHandler#handle returned an empty array. > Note: for implementations of ResultSetHandler that return a single object, rather than an array or collection, returning null does make sense. -- This message was sent by Atlassian JIRA (v6.2#6252)