Hello. This is my first post. I have a problem, it goes like this:

I have a Table named "Documents". Each document has a category and a sub-category. I also have a table named "Categories" and another one called "Sub-Categories". The categories table has 2 columns: 1)Id 2)Category name. The sub-categories table has 3 columns: 1)Id 2)Sub-Category name 3)Category ID . With a form, I add registries in the documents table. The form has 2 combo boxes. One for category and another one for sub-category, both based on the tables. The first combo box displays the category name, but stores the ID for that category. I also use this ID to filter the second combo box, to only display the sub-categories corresponding to the category selected in the first combo box. My problem is that in the documents table, under the Category field i see the category ID (the number). How can I display the category name in the documents table without changing the comboboxes properties, because it would affect my filter for the second combo box.

At first i choosed to store the ID to the table because then i could use this value to filter the second combo box, because the sub-categories in the sub-category table, are referred to the category ID and NOT to the name.

A possible solution is to tell access that when a number is entered in the documents table under the category field, search in the "Category" table, and return the name in that field. But i dont know how to do that.

Thanks!

Nevermind, I did it!:twisted:

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.