CBQE-0: fix array_agg

Change-Id: Iab07a02f846304aa4d7fd034624a6cf2d389f76e
Reviewed-on: http://review.couchbase.org/29896
Reviewed-by: Ketaki Gangal <ketakigangal@gmail.com>
Tested-by: Iryna Mironava <irynamironava@yandex.ru>