nothing
08-14-2005, 10:21 AM
Hello,
I wrote a very simple C program for managing clients and their buying and paying activities for an imaginary clothing store. For this version, I used simple text files but now I'd like to use MySQL. Let me explain how my program works first...
You enter a phone number and if the text file for that phone number is found, you have the following options:
Client is buying
Client is paying
Check total debit of the client
Show all transactions made by the client
Go back
If the text file for the phone number is not found, you have to register the new client and then you'll have the same options. Here's how the text file for one of the clients looks like after a couple of transactions:
Max Payne
123 Main Street
Springfield
NC
12345 (this is the zip code)
123456789 (this is the phone number)
#
bought sunday, 8/7/2005 534.00
534.00
paid monday, 8/8/2005 100.00
434.00
paid tuesday, 8/9/2005 100.00
334.00
The lines consist of the kind of the transaction, the date, and the total spent. The number on the line by itself is the total current debit of the client.
I already have an idea for the database design so I'll post it here and I hope you guys can give me some suggestions. Thanks a lot!
I wrote a very simple C program for managing clients and their buying and paying activities for an imaginary clothing store. For this version, I used simple text files but now I'd like to use MySQL. Let me explain how my program works first...
You enter a phone number and if the text file for that phone number is found, you have the following options:
Client is buying
Client is paying
Check total debit of the client
Show all transactions made by the client
Go back
If the text file for the phone number is not found, you have to register the new client and then you'll have the same options. Here's how the text file for one of the clients looks like after a couple of transactions:
Max Payne
123 Main Street
Springfield
NC
12345 (this is the zip code)
123456789 (this is the phone number)
#
bought sunday, 8/7/2005 534.00
534.00
paid monday, 8/8/2005 100.00
434.00
paid tuesday, 8/9/2005 100.00
334.00
The lines consist of the kind of the transaction, the date, and the total spent. The number on the line by itself is the total current debit of the client.
I already have an idea for the database design so I'll post it here and I hope you guys can give me some suggestions. Thanks a lot!