I have a question which i hesitated to ask, but since currently we have expert on duty
, i'd like to use such an opportunity.
Dear Mr. Ford:
Well, i'm implementing sort of inventory database. One of main features in it should be easy tracking of locations of different items.
The problem here is that it's not a warehouse's inventory where all aisles and shelves have numbers; this is much more chaotic environment - regular scientific lab with a lot of refrigerators, cabinets and stuff like that.
The initial idea was to build tree structure - each location is either parent or leaf with top locations having null parent (i have similar relationships in another part that implements protocol management but there situation is much easier).
For example:
null -> room 203->Brian's place->small freezer -20C->top shelf->Brian's box
Table looks something like this (in MySQL, need some refinements, never mind):
CREATE TABLE Locations (
LocationID INT NOT NULL AUTO_INCREMENT,
LocName CHAR(80) NOT NULL,
LocDescription TEXT,
LabMemberID INT DEFAULT NULL,
ParentLocID INT DEFAULT NULL,
INDEX(LocationID),
CONSTRAINT pk PRIMARY KEY(LocationID),
)TYPE=InnoDB;
It should work ok when i am presenting the item's details because the chain is not difficult to pull from db, but i have very vague idea about how to build convenient user interface for easy creation of new locations, and also the user should be able to create location on the fly: while filling out another form and at the same time he/she should have easy access to already defined locations.
I cannot build mental picture of all those combo boxes and text fields. It means that there should be more then one, say combo boxes and every next combo's display depends on what the user've chosen in preceding combo box...
My question is:
1. should i commit and try harder to figure out how to do it in practice or
2. it is too complicated and such an interface is impossible to make easy to use and it will be better and more practical to resort to simpler solution such as make user just to type location description and it will be an end of it?
3. did you ever had such a problem and how you solved it?
Best regards,
Svetlana