Look Sidewards - Reports DataPro / Standard Protocols

Jan Schenkel janschenkel at yahoo.com
Mon Sep 2 03:39:01 EDT 2002


--- Richard Gaskin <ambassador at fourthworld.com> wrote:
> Jan Schenkel wrote:
> 
> > [a very length description of a report]
> 
> How would you do all that in the HyperCard report
> engine?
> 

Hi Richard,

Admittedly, this wouldn't have been an easy one in the
HC report engine. It's been quite a while since I used
it, and never to the same extent as when I started
writing commercial applications in FoxBase/FoxPro (and
in Progress in a former life)

Off the top of my head, I think I would have had to
handle the subtotals myself, but as the data to
display is nearly the same as the detailed info, I
could have put everything into one background, with
those 8 fields.
(That is, merrily skipping the part where I get all
the data from a database and populate the card fields
with it)

<example content>

Card 1:
Field "Account number" : 100000
Field "Account name"   : Invested capital
Field "Period debit"   : 0.00
Field "Period credit"  : 0.00
Field "Period balance" : 0.00
Field "F.year debit"   : 0.00
Field "F.year credit"  : 15,500.00
Field "F.year balance" : 15,500.00

(...)

Card <i>:
Field "Account number" : <empty>
Field "Account name"   : Total: 1-----
Field "Period debit"   : 1,200.00
Field "Period credit"  : 5,600.00
Field "Period balance" : -4,400.00
Field "F.year debit"   : 3,400.00
Field "F.year credit"  : 27,500.00
Field "F.year balance" : -24,100.00

(...)

Card <z>:
Field "Account number" : Parameters
Field "Account name"   : 
  Only print accounts where balance <> 0
Field "Period debit"   : <empty>
Field "Period credit"  : <empty>
Field "Period balance" : <empty>
Field "F.year debit"   : <empty>
Field "F.year credit"  : <empty>
Field "F.year balance" : <empty>

</example content>

This is a situation which indeed could have been
handled by the standard HC report engine (the one we
got with version 2.1, iirc), with some work on the
part of the programmer.
Having used different development environments, it is
quite possible I've been spoiled by these dedicated
database products.
I've gotten used to making reports with data groups,
calculated variables, printing conditions and a
complete arsenal of expressions and formats.

RunRev provides us with a set of very useful commands
like 'clone', 'copy', 'paste' ; allowing us to write
some very powerful and flexible solutions.
Integration with data from revdb_cursors and other
sources could be accomplished by providing an extra
callback-parameter to a 'revPrintReport'-function,
which is called after a detail-band is 'printed' (ie:
created as a set of fields at the correct toplefts on
the card).
This 'getNextDetail' hook could call revdb_movenext,
fetch additional data from arrays and put them in
variables, etc.

At least, that's what I had in mind when I studied the
feasibility of writing our own report generator in
RunRev, in case there was none in the forseeable
future, by the time we would need it in our
development process.

Am I to conclude from your question that the RunRev
report generator will be very similar to HC's ? To be
honest with you, I haven't checked out the RunRev 1.5
beta, mainly because I lack the time.
So I have no idea of whether or not a report generator
is in there, nor what it could do were it scheduled
for this next version.

If you'd prefer to continue this discussion off-list,
I'd be more than happy to oblige ; as I don't wish to
make people think RunRev is lacking.
RunRev is a _very_ powerful environment ; the built-in
access to very diverse fields as multimedia, databases
and so much more, is impressive to say the least.

And I'm sure everybody has their wish-lists :-)

Best regards,

Jan Schenkel.

"As we grow older, we grow both wiser and more foolish
at the same time."  (De Rochefoucald)

__________________________________________________
Do You Yahoo!?
Yahoo! Finance - Get real-time stock quotes
http://finance.yahoo.com



More information about the use-livecode mailing list