baan_fun
7th April 2004, 12:48
Hi,
I'm facing the following problem in Baan 5c.
History
---------
I created a session (session A) where user insert some search criteria for a common search on 3 tables (Table X,Y,Z for ex.)
With the search results for table X I zoom to session (B) where I display the records from table W (main table) that were also found in table X,Y or Z (Table X,Y,Z,W have a common field (xyzw.field) that is index1 in table W and index2 in tables X,Y,Z)
Fact
------
I have built the logic as follws:
declaration:
extern domain tcmcs.str10 array(1000) based
extern domain
In session A : (no main table)
-----------------------
choice.def.find:
on.choice:
set.mem(array,"")
i = 0
Step 1.
select X.xyfield
by form search criteria
order by X._index1
selectdo
i = i + 1
array(1,i) = xy.field
endselect
Step 2.
... fill in array by further reading of tables Y and Z
Step 3.
export("array", array)
export("i",i)
start.session(MODAL, "SESSION B", "SESSION A", "")
In session B (main table Y)
----------------
Step.4
long j.i
extern domain
before.program:
import("array", array)
import("i",i)
for j = 1 to i
query.extend.where
I'm facing the following problem in Baan 5c.
History
---------
I created a session (session A) where user insert some search criteria for a common search on 3 tables (Table X,Y,Z for ex.)
With the search results for table X I zoom to session (B) where I display the records from table W (main table) that were also found in table X,Y or Z (Table X,Y,Z,W have a common field (xyzw.field) that is index1 in table W and index2 in tables X,Y,Z)
Fact
------
I have built the logic as follws:
declaration:
extern domain tcmcs.str10 array(1000) based
extern domain
In session A : (no main table)
-----------------------
choice.def.find:
on.choice:
set.mem(array,"")
i = 0
Step 1.
select X.xyfield
by form search criteria
order by X._index1
selectdo
i = i + 1
array(1,i) = xy.field
endselect
Step 2.
... fill in array by further reading of tables Y and Z
Step 3.
export("array", array)
export("i",i)
start.session(MODAL, "SESSION B", "SESSION A", "")
In session B (main table Y)
----------------
Step.4
long j.i
extern domain
before.program:
import("array", array)
import("i",i)
for j = 1 to i
query.extend.where