src/com/holub/database/DefaultSelect.java
/** 
	 * make cartesian product & select using where clause
	 * @param 
	 * @return 
	 */
make cartesian product & select using where clause
@param
@return
make cartesian product & select using where clause @param @return
private void selectFromCartesianProduct(int level, Selector where, String[] requestedColumns,
			Table[] allTables, Cursor[] allIterators, Table resultTable) {
		allIterators[level] = allTables[level].rows();
		while (allIterators[level].advance()) { 
			if (level < allIterators.length - 1)
				selectFromCartesianProduct(level + 1, where, requestedColumns, allTables, allIterators, resultTable);
			if (level == allIterators.length - 1) {
				if (where.approve(allIterators))
					insertApprovedRows(resultTable, requestedColumns, allIterators);
			}
		}
	}
private void selectFromCartesianProduct ( int level , Selector where , String [ ] requestedColumns , Table [ ] allTables , Cursor [ ] allIterators , Table resultTable ) { allIterators [ level ] = allTables [ level ] . rows ( ) ; while ( allIterators [ level ] . advance ( ) ) { if ( level < allIterators . length - 1 ) selectFromCartesianProduct ( level + 1 , where , requestedColumns , allTables , allIterators , resultTable ) ; if ( level == allIterators . length - 1 ) { if ( where . approve ( allIterators ) ) insertApprovedRows ( resultTable , requestedColumns , allIterators ) ; } } }
make cartesian product & select using where clause
 @param
 @return
make cartesian product & select using where clause @param @return