Array[] columns=new Array[arr.length];
int count=0;
for(int i=0;i<arr.length;i++) {
if(arr[i] instanceof FunctionValue) {
FunctionValue vf = (FunctionValue)arr[i];
if(vf.getValue() instanceof Array) {
names[count]=vf.getNameAsString();
columns[count]=(Array) vf.getValue();
count++;
}
else throw new DatabaseException("invalid argument for function query, only array as value are allowed","example: query(column1:array(1,2,3))",null,null);
}
else throw new DatabaseException("invalid argument for function query, only named argument are allowed","example: query(column1:array(1,2,3))",null,null);