I just gave a database diagram for a DB I created to our head database person, and she put a bunch of notes on it suggesting that I rename certain tables so it is clear they are lookup tables (add "lu" to the beginning of the table name).
My problem is that these don't fit the definition of what I consider a lookup table to be. I have always considered a lookup table to basically be a set of options that don't define any relationships. Example:
luCarMake ----------- id Make -- --------- 1 Audi 2 Chevy 3 Ford
The database person at my work is suggesting that I rename several tables that are just IDs mapping one table to another as lookup tables. Example (Location_QuadMap below):
Location ---------- LocationId name description Location_QuadMap <-- suggesting I rename this to luLocationQuad ---------------- QuadMapId LocationId luQuadMap --------- QuadMapId QuadMapName
Is it safe to assume that she misread the diagram, or is there another definition that I am not aware of?
In data analysis applications, such as image processing, a lookup table (LUT) is used to transform the input data into a more desirable output format. For example, a grayscale picture of the planet Saturn will be transformed into a color image to emphasize the differences in its rings.
Lookups are an intuitive table linking syntax provided to simplify data integration and SQL queries. They represent foreign key relationships between tables, and once established, can be used to "expose" columns from the "target" of the lookup in the source table or query.
Lookup tables provide the essential function of helping you maintain data integrity in your database environment. For example, if you have users entering their gender into a data item, the table that contains the Gender item can reference a lookup table to verify that only the value M or F is used.
LOOKUP tables in Excel are named tables used with the VLOOKUP function to find any data. When we have a large amount of data and do not know where to look, we can select the table and name it.
What you have there is called a junction table. It is also known as:
But I've never seen the term "lookup table" used for this purpose.
Pick your battles, but I'd ask for the person to clarify the naming convention seeing that they've suggested using the same convention for one-to-many and many-to-many relationships. Looks like any foreign key relationship means there's a "lookup" table involved.
If that's the naming convention for other databases, then I wouldn't push my luck.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With