Storing dataset in BIRT array variable

Iam running a Dataset on a datasource, i need to use one column values out of the data set to another Dataset which is connected with another datasource.


So i need to store the Array of row['column_name'] to a variable.


I tried creating a page variable and on fetch method i tried using,

uoi[i] = row["uoi_id"];

i++;

vars['ids']=uoi;


I was getting no report param called ids, but created one


Then i tried to create globalVariable, 

reportContext.setGlobalVariable('uoiids', ["1"]);


while reading this am getting null. 


[b]Approach2[/b]:

Since this is not working, what i tried is creating a Dynamic param as List, and provided my dataset and column mapping.


And in my 2nd dataset, i used params['ids']


This worked, but the problem is on report param i need to manually select all the values, i need to somehow auto select all the options. 

I tried using getDefaultList event, but i dont know how to return the list of array.


And i read in a post getDefaultList will trigger before reading the dataset itself.

I need to atleast know how to select all values by default. 


When i tried to Post this in BIRT forum, its saying incorrect password evn thought its right one