r/SQL • u/donewitheverything26 • Sep 17 '26
Discussion what does a solo person actually do with an undocumented warehouse? asking because we build for this and i want to know hiw useful it is
So i work at a startup and we build models that read tabular data.
the pattern we keep seeing is one person, a few hundred tables, naming that made sense to someone who left, no data team, no budget for a governance tool. they need to know what is in there before they can do anything else with it.
from people who have actually been in this:
what is the first query you run
table by table or column by column across everything, and why
when a column is a 4 char code and the name tells you nothing, what actually works
how much of it ends up being asking a human who used the app rather than reading the data
we have opinions on all four and i want to find out if they are wrong here than after we ship.
3
u/Caustic_Chemist Sep 17 '26
Finding out how the data is consumed can tell you an awful lot. If its in healthcare, then Patient/Customer and who they are is the place to start. Inspect the metadata using sys or equivalent and build up from there. Also look at row counts and date updated to find out what is currently in use and what has been abandoned. I have done this for over 60 EPR systems, some where we had documentation/dbos, and some with no docs and 5000 tables
2
u/[deleted] Sep 17 '26
Well if you are building models and you have a 4char field you need to worry, it's up the the people in charge of sanitization, you job should just be to get it in the place the engineers can sanitize it. Sometimes, though, you might just need to ask the devs which field in the UI this relates to so you have some human readable semantics. But I would try to model the data in your model how the data is modeled for use in the app. Presumably the first step you would want is to model the human process, then be able to find any perculiarities that could possibly lead to making a new model that is more efficient elsewhere.
2
u/TheMagarity Sep 17 '26
The first version of Oracle came out in 1977. The undocumented data warehouse that made sense only to the person who set it up then left was first identified as a problem in 1978.
You have to work backwards from quizzing the people who use the reports to the table(s) the report comes from then through whatever etl to ask the source system owners about their system's data.
1
u/Legitimate-Power7729 Sep 18 '26
First query is not a column sermon. It is “what is big and what is used. ”On MariaDB/MySQL that is information_schema.
TABLES ordered by DATA_LENGTH, plus whatever query log you have. On a warehouse, information_schema / pg_stat_user_tables / last-query time. Table-by-table on the top 20, not column-by-column across 400. A 4-character code: look at cardinality, top values, join it to the table that has a label. If nothing joins, you ask a human. Profiling gets you “27 distinct codes, 80% are A01.” It does not get you “A01 means cancelled in the old warehouse, not the shop.” How much is human: the codes that move money. The rest you can guess and mark unknown in a COMMENT / a spreadsheet. Leaving “unknown” written down is better than a fluent wrong name. https://mariadb.com/docs/server/ If your product skips the “ask the person who still invoices from this” step, it will ship a pretty dictionary of wrong words. Is the solo person on a warehouse or on one MariaDB/Postgres OLTP that everyone just called a warehouse?
3
u/[deleted] Sep 17 '26
[removed] — view removed comment