MySQL Two User Database Consolidation

I am redesigning a database and I need some help.

I have two "User" tables, USER and APPLETCUST, with one being an internal user and the other being a customer.

Since I want them both to login to the same area, I think I need to create a new table that holds login information and whether or not the person is a USER or an APPLETCUST and then have a relationship to the respective USER or APPLETCUST to get that information.

What do you think? Is there a better way?


I'd recommend merging the table, but you already suggested it yourself :-) Creating a third table that references the two tables is also possible but might get messy unless you write the constraints properly.

Need Your Help

Define dictionary without Types gives compiler error in Swift

swift data-structures

I don't know the datatypes ahead of time, how can I add data to the empty dictionary without types. Looks like someone asked the same question here but no answer was accepted How to create Dictionary

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.