Dear experts
How to fetch data from multiple form to one form using al for 365 business central ?

Dear experts
How to fetch data from multiple form to one form using al for 365 business central ?
finally Solution is below
first should be create query of respective tables
query syntax is below
table1
query 5010 queryname(respective table name )
{
QueryType = Normal;
Caption = 'query name ';
elements
{
dataitem("tablename"; "tablename")
{
column("fieldname"; "fieldvalue") { }
}
}
}
table 2
query 5011 queryname(respective table name )
{
QueryType = Normal;
Caption = 'query name ';
elements
{
dataitem("tablename"; "tablename")
{
column("fieldname"; "fieldvalue") { }
}
}
}
then pass the function to respective page syntax is below
local procedure procedurename()
var
variable1: Query table1;
variable2: Query table2;
variablecurrentpage: Record current page ;
begin
variable2.setfilter('fieldof variable2','current page.filed');
variable1.setfilter('fieldof variable1','current page.filed')
variable1.open();
while variable1.Read do begin
while variable2.Read do begin
variablecurrentpage.SetFilter(fields,fields)
variablecurrentpage.init();
variablecurrentpage.field :=variable1.field ;
variablecurrentpage.insert()
end;
end;
end;