📨 Have you signed up to the Forum's new Email Digest yet? Get a selection of trending threads sent straight to your inbox daily, weekly or monthly!
Help with a database
hemophobic
Posts: 739 Forumite
in Techie Stuff
I have to do a database project for college and I have a question about Drop down boxes e.g for title I've set it so I can pick from mr mrs ms miss etc. My database is for a jewellery shop and I was wondering if it is possible if I can have different drop down boxes for a certain field depending on another field I.e if ring is selected as the jewellery type I would like the size drop down box to display a,b,c etc but if bracelet was selected as the jewellery type I would like the size drop down box to show small, medium, large etc. Is this possible and how would I do it?
0
Comments
-
If you use an Excel spreadsheet, you can set up a pivot table - an example is found at http://www.homeandlearn.co.uk/ME/mes9p4.html0
-
Firstly, what software are you intending to use? If MS, Access is a great database program. If you want a simple layout, then Excel (which is a spreadsheet program) could be used. I forget how to do it in Access (try hitting F1 and it'll tell you) but I remember in Excel click Data/Validation/Settings and from the drop down box, select list (a 'source' box will pop up).
Before you do that though, go a few cells to the right of where you want the 'database' data to be and enter your list in separate cells (one on top of the other). You can then click the red arrow in the source box and simply select your list, and click ok. Once you've done this select the cell, and drag it down (by selecting the cross in the bottom right of the cell) as far as you like which will copy this list format to all the cells in the column.
This will only give you a simple list though, you cannot make a 'list within a list' using this method. But of course you could make a column called 'type' containing ring, bracelet, necklace etc. and another called 'size' etc with a list in each.
Marching On Together
I've upped my standards...so up yours!
0 -
I am using MS Access 2007 I'll look at the help menu.0
-
Look at the 'afterupdate' event of the first box.
In this event you can set the rowsource() of the 2nd box to whatever you want. You may want to set the value of the 2nd box to null if you change the first box.Debts: Virgin Card [STRIKE]£5,600[/STRIKE] £5,636, First Direct [STRIKE]£7,700[/STRIKE] £7,000, Halifax [STRIKE]£3,200[/STRIKE] £3,810, Halifax Clarity [STRIKE]£755[/STRIKE] £711, Tesco [STRIKE]£4,005[/STRIKE] £4,450, MNBA [STRIKE]£6,700[/STRIKE] £6,580, Loan [STRIKE]£15,834[/STRIKE] £15,218 Total: [STRIKE](45K at highest) £43,794k[/STRIKE] £43,4050 -
You can use a number of methods of supplying data into a drop-down box (known in Access as a Combo Box). If all you are going to do is use a number of simple fixed data types - like Mr, Mrs, Countries for example then you could write these into a separate table and have the data brought through into your main table by going to the Lookup tab (in Table design view) selecting "Combo Box" and then selecting your Rowsource (the name of your subsidiary table).My very sincere apologies for those hoping to request off-board assistance but I am now so inundated with requests that in order to do justice to those "already in the system" I am no longer accepting PM's and am unlikely to do so for the foreseeable future (August 2016).

For those seeking more detailed advice and guidance regarding small claims cases arising from private parking issues I recommend that you visit the Private Parking forum on PePiPoo.com0 -
I wonder what the op did?Debts: Virgin Card [STRIKE]£5,600[/STRIKE] £5,636, First Direct [STRIKE]£7,700[/STRIKE] £7,000, Halifax [STRIKE]£3,200[/STRIKE] £3,810, Halifax Clarity [STRIKE]£755[/STRIKE] £711, Tesco [STRIKE]£4,005[/STRIKE] £4,450, MNBA [STRIKE]£6,700[/STRIKE] £6,580, Loan [STRIKE]£15,834[/STRIKE] £15,218 Total: [STRIKE](45K at highest) £43,794k[/STRIKE] £43,4050
This discussion has been closed.
Confirm your email address to Create Threads and Reply
Categories
- All Categories
- 355.8K Banking & Borrowing
- 254.9K Reduce Debt & Boost Income
- 456.2K Spending & Discounts
- 248.4K Work, Benefits & Business
- 606K Mortgages, Homes & Bills
- 179K Life & Family
- 263.8K Travel & Transport
- 1.5M Hobbies & Leisure
- 16.2K Discuss & Feedback
- 37.7K Read-Only Boards