conglomNumbers = new long[size];
isSelfReferencingFK = new boolean[size];
raRules = new int[size];
ForeignKeyConstraintDescriptor fkcd = null;
TableDescriptor fktd;
ColumnDescriptorList coldl;
int[] refColumns;
ColumnDescriptor cold;
int[] colArray = remapReferencedColumns(cd, rowMap);
for (int inner = 0; inner < size; inner++)
{
fkcd = (ForeignKeyConstraintDescriptor) fkcdl.elementAt(inner);
fkSetupArrays(dd, fkcd,
inner, uuids, conglomNumbers, fkNames,
isSelfReferencingFK, raRules);
if((raRules[inner] == StatementType.RA_CASCADE) ||
(raRules[inner] ==StatementType.RA_SETNULL))
{
//find the referencing table Name
fktd = fkcd.getTableDescriptor();
refTableNames.addElement(fktd.getSchemaName() + "." + fktd.getName());
refActions.addElement(new Integer(raRules[inner]));
//find the referencing column name required for update null.
refColumns = fkcd.getReferencedColumns();
coldl = fktd.getColumnDescriptorList();
ColumnDescriptorList releventColDes = new ColumnDescriptorList();
for(int i = 0 ; i < refColumns.length; i++)
{
cold =(ColumnDescriptor)coldl.elementAt(refColumns[i]-1);
releventColDes.add(cold);
}
refColDescriptors.addElement(releventColDes);
refIndexConglomNum.addElement(new Long(conglomNumbers[inner]));
fkColMap.addElement(colArray);
}