Bug 155262 Total.countDistinct() method returns null on empty resultset
If you use Total.countDistinct(row.aColumn, null, 0) or Total.countDistinct(dataSetRow.aColumn, null, 0) and the resultset for the dataset is empty, the method returns null. It should return 0.
data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/impl/aggregation/JSAggrValueObject.java
* @param hasOdiResultDataRows
	 */
	JSAggrValueObject( List aggrExprInfoList, IResultIterator odiResult,
			List[] aggrValues )
	{
		this.aggrExprInfoList = aggrExprInfoList;
		this.odiResult = odiResult;
		this.aggrValues = aggrValues;
		this.aggrCount = aggrExprInfoList.size( );
	}
	
	/*
	 * @see org.mozilla.javascript.Scriptable#getClassName()
	 */
	public String getClassName( )
	{
		return "_RESERVED_AGGR_VALUE";
	}
	/*
	 * @see org.mozilla.javascript.Scriptable#has(int,
	 *      org.mozilla.javascript.Scriptable)
	 */
	public boolean has( int index, Scriptable start )
	{
		return index > 0 && index < this.aggrCount;
	}
	/*
	 * @see org.mozilla.javascript.Scriptable#get(int,
	 *      org.mozilla.javascript.Scriptable)
	 */