Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   Index   Templates   Seminars   TechHelp   Forums   Help   Contact   Join   Order   Logon  
 
Home > Courses > Access > Expert > X02 > < X01 | X03 >
Back to Access Expert 2    Comments List
Upload Images   Link   Email  
Companies in Different Tables
Abdulhadi Qasem 
   
3 years ago
hi thank you very much for your classes i am enjoying a lot, just now reviewed lesson 4 ( Value Across Forms )

small question what if i have 3 different tables for companies  for example, table for hotels , table for airlines, table for not either hotels or airlines - e.g.company to supply the bus.

based on this lesson to supply the company id, i should do 3 lists ( hotels, etc ) to open their form then a button to open orders or contacts and to supply the company id .

is there a better way? maybe through VBA i can make combo box that i chose first is it hotels or airlines etc then to choose one based on the previous combo box.
Kevin Robertson 
          
3 years ago
Scott Axton 
          
3 years ago
The better way is  to have only 1 table for the companies.  Then make a second table to assign the business category type (Hotel, Restaurant, Airline, etc.)
BUT what happens if a company can do multiple things?  Hotel and Restaurant for instance.
Then you would need a 3rd "junction" table.
The best way is to keep going in your courses in order.  You will learn as you go the better methods.

If you want to jump ahead:
Normalizing Data
Relationships
Many-to-Many
Abdulhadi Qasem OP 
   
3 years ago
hi Scott and Kevin thank you for your reply

i cant store them in one table as hotel table is linked with a table showing booking details like check in date, number of rooms booked etc.

and the airline (company name) table is linked with some tables showing the details of the flight etc

the third table is to to store companies that offer buses services, hotels (sometimes we book hotels from local agency) so as you said the third table i can add category type (bus company, Local Agency Travel etc)

thats why i need 3 tables to store my suppliers. i have companyID attribute that is coming from three different tables.

i am modelling accounting system for travel agency that is offering Groups Travels .
Richard Rost 
          
3 years ago
I would still use one table for all of the different companies, and then if you need separate data for each, make related 1-to-1 tables for them. Your main CompanyT would have the fields that are common to all of them (name, address, phone, etc.) and then for the airlines you could have a related AirlineInfoT that had info specific to just airlines. But that's just my advice.
Abdulhadi Qasem OP 
   
3 years ago
wooow another solution from different angle . i will wait as you said don't jump into your project until later stage. thank you very much. God Bless You
Richard Rost 
          
3 years ago
I've actually got a TechHelp video on this coming out soon... look for it. Someone else asked me a very similar question.
Richard Rost 
          
3 years ago
Abdulhadi, here's the video: Too Many Tables. It's literally the same thing that Scott said to do, above. :)
Abdulhadi Qasem OP 
   
3 years ago
yes i saw it in youtube, thank you very much.
i will wait
i will not do anything in my project.

This thread is now CLOSED. If you wish to comment, start a NEW discussion in Access Expert 2.
 

 
 
 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2025 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 3/16/2025 12:14:29 PM. PLT: 1s