Hello there,
I am learning php/mysql by doing a small project. The project is like "storing shopping list as a file in database and retrieve it" to update later on or to generate reports. The confusion I am having is:
- How to store a file with (n) number of records (a user can have (n) number of items in one shopping list).
- Save this shopping list and retrieve it some other time.
- How to store "New shopping list for every new trip" in the database?
I have installed XAMPP 1.7.4 on windows XP, mysql version is 5.0.7, php version 5.3.5
I have 1 database containing 3 tables: shopping_list, item_master and brand_master
Item_Master has 1 column = item_name
Brand_Master has 1 column = brand_name
shopping_list has 4 columns = item_name, brand_name, quantity, file_name
What I want to do is:
Before going to shopping, I want to make a list and want that list to be stored in database as a file. This file should be saved as any name given. Later, anytime I should be able to open the file for printing or for any addition/ deletion.
So there could be "n" number of shopping lists with "n" number of items as every time we go for shopping we have new items in our list.
Lastly (at this moment), I want to generate an itemized report date-wise.
So far, what I have done:
1. Created database, tables and forms.
2. Connection between Database and forms (Entries done in Item_Master and Brand_master, shows up as a drop-down list in "shopping_list form"
3. I am trying to save it as a file and retrieve accurate data according to each file but don't know how to do it.
Any help/ link to the tutorial for working with the files will be appreciated.
Thanks