Actually am a BO XI beginner ,so have stuck in the basic concept of derived table..if any one explain it for me,i ll be grateful to them,and plz explain in which context i should use the derived table.
Derived tables are not real tables at the Database level , but are the selection of few columns in the Table with some aggregations, specific to the report.
This feature is available in BO 6.5 and later versions.
Sel a1,a2,a3,max(a4)
from a ,
(Sel b1, b2, max(b3) as B3, Min(B4) as B4 from B group by b1,b2) as BX
where BX.B1= a.a1 group by a1,a2,a3 order by a1,a2,a3
The (Sel b1, b2, max(b3) as B3, Min(B4) as B4 from B group by b1,b2)Â in the above query is a derived table.
The same definition has to be added in the Universe - by going into Insert >> Derived Tables.
Type the Query - parse it and the new table inserted can be used to any type of join / Contexts etc in the Universe.
For Derived table, i am having one scenario. My Database table is having following Column -Empno -Empname -Managerno
my Report Requirement is like: report should display Emp name and its corressponding manager name.
Based on this reqquirement, i need to design Universe.
My steps would be like this: 1.Looking at the requiement, i would go for Derived table, having name Manger.
Derived Table(Manager) would be having following syntax.
select distinct a.EmpNo,b.EmpName from Emp a,Emp b where a.ManagerNo=b.EmpNo
2. Joining
2. Create class Manager and Object Manager Name, Source for this object would be Derived_table.EmpName that is manager. EmpNo. Here EmpNo is coming from Derived table syntax.
Now my universe is ready.
As per the repoer requirement i can create report.
So Bottom line is Derived table plays a major role in this scenario.