Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to create One-to-many report without using the wizar
Message
From
16/04/2002 05:10:52
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
15/04/2002 23:19:44
Hee Lim Wang
Fantasy Software Enterprise
Malaysia
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00645281
Message ID:
00645334
Views:
7
>Why my detail data in report shows only 1 record ?
>I create 2 cursors in init and set relation to them.
>My report does not have any cursor in data environment,
>but I want to make it into One-to-many report.How ????
>
>*form.init
>Create Cursor detail(ac c(10),amount N(12,2))
>INDEX ON ac TAG ac
>
>CREATE CURSOR account(ac c(10),name c(20))
>INDEX ON ac TAG ac
>SET RELATION TO ac INTO detail
>SET SKIP TO detail
>.......add some records into curosr.......
>report form MyReport preview

Hee,
You'd reverse the relation from child to parent (and no set skip). However it's much easier to select into a cursor all data you need and report from there. ie :
set ansi on
select a.ac, a.name, b.amount ;
 from account a ;
 inner join detail b on a.ac = b.ac ;
 into cursor crs2Report
report form myreport ...
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform