Beginning Xbasic Programming
Puzzle 9 - Dump ta dump
You solved Puzzle 6, 7, & 8 but NOW your sales manager tells you
that the list of product sales doesn't do anyone any good displayed on
screen. She needs the list of sales in a text file she can print or
send to others. After noting that it took you longer to do the
descending sort that she had expected, she says dumping the
list to a disk file should be trivial. After all, you're dumping it
to the trace window already, right?
After contemplating what you might want to "dump" on your manager,
you realize that your job now is to write an xbasic script that will list
each product in the Inivoice_items table and for each product show the
total dollars generated by that item across all the invoices. Your list
should be sorted in descending order based on total dollars generated
by each item. And, finally, the list must be written to disk in a simple
text file.
Instructions:
a) you may not use any of the built in summary functions, methods,
or operations in Alpha Five. We're totaling sales without using
any of the built-in summarization tools Alpha provides.
b) you may open the table only once
c) your output should be written to a disk file named "Puzzle_9_Sorted_List.txt"
in a folder called "Temp" on your "C" drive.
d) export your solution script and attach it to your reply, here
e) attach a copy of the text file your script creates when you submit your
solution here
Puzzle 9 - Dump ta dump
You solved Puzzle 6, 7, & 8 but NOW your sales manager tells you
that the list of product sales doesn't do anyone any good displayed on
screen. She needs the list of sales in a text file she can print or
send to others. After noting that it took you longer to do the
descending sort that she had expected, she says dumping the
list to a disk file should be trivial. After all, you're dumping it
to the trace window already, right?
After contemplating what you might want to "dump" on your manager,
you realize that your job now is to write an xbasic script that will list
each product in the Inivoice_items table and for each product show the
total dollars generated by that item across all the invoices. Your list
should be sorted in descending order based on total dollars generated
by each item. And, finally, the list must be written to disk in a simple
text file.
Instructions:
a) you may not use any of the built in summary functions, methods,
or operations in Alpha Five. We're totaling sales without using
any of the built-in summarization tools Alpha provides.
b) you may open the table only once
c) your output should be written to a disk file named "Puzzle_9_Sorted_List.txt"
in a folder called "Temp" on your "C" drive.
d) export your solution script and attach it to your reply, here
e) attach a copy of the text file your script creates when you submit your
solution here
Comment