MySQL shared table or table in each database

I have such a situation, in my system there are many databases and for some queries I need to use the same table "hours", which basically has one field 'h' and stores hours like '00',...,'23'.

My question is about efficiency, is it better to create separate database and store this table there or have this table in each database. My queries will look like:

SELECT ... FROM hours CROSS JOIN some_table ...

Thank you!


Either way, you'd be having to modify all the "non-local" queries to use that table

FROM sometable
CROSS JOIN dbname.hours

If it's stuck into its own database, then you have to modify ALL queries. If it's in one of the 'real' databases, you only have to modify n-1 queries. Plus having to grant appropriate permissions on that table if you're using multiple different mysql accounts for the different databases.

Need Your Help

How to build a WebAPI for remote authentication?


We are thinking about revising our existing membership provider into web service to allow remote authentication. Say, a windows 8 application will be able to accept login credentials and check it i...

Dropdown Selection error when i select the item from dropdown list


when i run my code than it send the error that Object reference not set to an instance of an object in dropdown list 4.