General information
Category:
Reports & Report designer
Title:
Problem with 2 detail bands in VFP 9.0
Hello Everybody !
(9.0 greenhorn !!)
I have 2 cursors as results from 2 sql-commands against an server database.
cursor1 (order by id,year,month,date)
id,year,month,date(dd-mm-yyyy) ,kz ,worth
1 ,2005,01 ,01-01-2005 ,aa , 1.5
1 ,2005,01 ,02-01-2005 ,bb , 3.5
1 ,2005,01 ,03-01-2005 ,aa , 1.5
1 ,2005,01 ,04-01-2005 ,aa , 2.5
1 ,2005,01 ,05-01-2005 ,bb , 4.5
1 ,2005,01 ,06-01-2005 ,cc , 0.5
1 ,2005,02 ,01-02-2005 ,aa , 2.5
1 ,2005,02 ,02-02-2005 ,bb , 3.0
1 ,2005,02 ,03-02-2005 ,aa , 4.0
1 ,2005,02 ,04-02-2005 ,cc , 2.0
1 ,2005,02 ,05-02-2005 ,bb , 4.0
1 ,2005,02 ,06-02-2005 ,cc , 1.0
2 ,2005,01 ,01-01-2005 ,aa , 1.5
2 ,2005,01 ,02-01-2005 ,bb , 3.5
2 ,2005,01 ,03-01-2005 ,aa , 1.5
2 ,2005,01 ,04-01-2005 ,aa , 2.5
2 ,2005,01 ,05-01-2005 ,bb , 4.5
2 ,2005,01 ,06-01-2005 ,cc , 0.5
...
cursor2 contains the totals for each id,year,month,kz combination
(order by id,year,month,kz)
id,year,month,kz,kzcount,kzworth
1 ,2005,01 ,aa,3 ,5.5
1 ,2005,01 ,bb,2 ,8.0
1 ,2005,01 ,cc,1 ,0.5
1 ,2005,02 ,aa,2 ,6.5
1 ,2005,02 ,bb,2 ,7.0
1 ,2005,02 ,cc,2 ,3.0
2 ,2005,01 ,aa,3 ,5.5
2 ,2005,01 ,bb,2 ,8.0
2 ,2005,01 ,cc,1 ,0.5
...
I want to print an report looking like this:
***************************************************
(top of new page)
id month year
(detail1 band)
01-01-2005 ,aa , 1.5
02-01-2005 ,bb , 3.5
03-01-2005 ,aa , 1.5
04-01-2005 ,aa , 2.5
05-01-2005 ,bb , 4.5
06-01-2005 ,cc , 0.5
(detail2 band)
summary for month 01
aa,3 ,5.5
bb,2 ,8.0
cc,1 ,0.5
next page = next month same id or new id
************************************************
i tried with 2 detail bands
target alias for detail band 1 = "cursor1"
target alias for detail band 2=
detail band 1 ok
detail band 2 only 1 (first of cursor2) record ???
Any help welcomed
Best regards
Albert
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only