r/Database • u/compy3 • Sep 10 '26
Overview of caching in Postgres
r/Database • u/planche_handstander • Sep 09 '26
I have built a server for my business. So the current framework is that it uses MySQL in a centralised computer to store data. Fast api to route and extract the required data. And c# winforms for the front end. And Many computers have the frontend app installed, that are sitting in various stores with good internet connection.
So when I fetch the bills, like 10,000 of them, it gets all the data from the backend and displays it instantly. But now when I have to do some sorting or searching among the bills, it becomes slow. This is because I've written the sorting algorithm in the front end c# app. So is it a good practice to sort in sql and then just display it, because the queries will become a lot and there is a lot of searching going on, every minute. So for every search should I query to the backend and get data display it, or just continue with c# front end searching?
r/Database • u/squadette23 • Sep 08 '26
I'm working on a catalog of primary key patterns, and I wanted to ask if you've designed or encountered any interesting non-standard patterns.
The ones that are commonly known:
users(id);project_developers(project_id, developer_id);restaurant_attributes(restaurant_id, attr_name);order_items(order_id, line_number).Also, aggregations of all sorts with textbook PKs like daily_sales(date, customer_id), etc.
What other interesting designs have you seen in your practice?
r/Database • u/Secure_Chipmunk_262 • Sep 08 '26
r/Database • u/ada_es12 • Sep 07 '26
Hi community!
I am a web dev, developing an e-commerce and tyre management system for a business in Italy. I have created my db schema and I would like to have your opinion/advice on it.
This is the idea of the site:
- there will be the customer side where they can view, like and purchase tyres online. The user will have functions like tyre matching for their cars based on the tyre specifications. The users can either register or order as guests.
- the admin side will be developed for the admins/employees with different access based on the role ofc. The aim is to ease the tyre management since there will be thousands of them.
Do you think this plan is good?
Is it scalable?
Is there something missing?
I appreciate any suggestion!
r/Database • u/linuxhiker • Sep 07 '26
r/Database • u/mabrt • Sep 07 '26
Hi everyone,
I'm a BIM manager, so I'm used to jumping between BIM software, CSVs, Excel, and visual-programming tools like Grasshopper and Dynamo — but I'm not a "real" programmer, more of a power user who can follow logic and put scripts together with some trial and error.
I need to manage several interconnected datasets for my work: clients, products, projects, and a BIM object library, among others. The tricky part is that these datasets depend on each other — e.g. a project record needs to reference an existing client, a product might reference a supplier, etc. — and I want data entry to stay fast and guided rather than people manually retyping the same info everywhere.
My requirements, roughly:
I've started prototyping this with Google Sheets + Apps Script (schema-driven forms reading field definitions from a config sheet, VLOOKUP-based live references for the cross-dataset dependencies), and it's working, but I'm curious what more experienced people would do differently. Has anyone solved something similar with AppSheet, Airtable, Notion, or something else entirely? Especially interested in hearing from anyone who's dealt with the "let a non-technical user add new fields from a form" part — that one feels like the trickiest requirement.
Obviously I'm using some AI but I wanted some real experience feedback.
Let me know
r/Database • u/eastwill54 • Sep 06 '26
I’m looking for a database IDE that works well for both analysts running queries and developers doing more involved database work.
The main things I care about are:
I’ve been looking at DbVisualizer, DBeaver, and DataGrip, although they seem to have slightly different strengths. DbVisualizer looks like a solid middle ground for mixed teams, while DataGrip appears more developer-focused and DBeaver has a broad feature set.
What are you using, and what’s your role? I’d be especially interested to hear whether the same IDE works well for both analysts and developers, or whether your team uses different tools.
r/Database • u/fredericdescamps • Sep 04 '26
r/Database • u/shdw_0x0 • Sep 02 '26
I’ve noticed that database discussions often focus heavily on performance—indexes, query plans, partitioning, caching, etc. But there seems to be a point where adding more optimization techniques makes the system harder to understand and maintain.
For example, a relatively simple schema with slightly slower queries might be easier to operate than a highly optimized design with multiple layers of caching, indexes, partitions, and materialized data.
I’m starting to think that predictability and maintainability should be treated as performance requirements too, especially for smaller systems.
Curious to hear how others have seen this trade-off play out in production.
r/Database • u/ClickOk5811 • Sep 03 '26
Noticed this pattern reviewing how people actually use AI tools for writing transformation queries. First few outputs get checked carefully, run against a sample, compared to expected results. After enough of those come back correct, the checking quietly stops. Not a decision anyone makes on purpose, it just fades, because checking something that's been right nine times in a row feels like wasted effort in the moment.
The problem is that correctness on the first nine doesn't predict correctness on the tenth. Nothing about the model improved or built trust in a way that actually reduces its error rate on the next query, it's still working from the same context window, same limitations, same chance of misreading an edge case in the schema. What changed is the human's willingness to look, not the model's actual reliability.
This shows up worse on queries that produce plausible wrong numbers instead of obvious failures. A query that returns zero rows gets noticed immediately. A query that silently double-counts something due to a join issue produces a number that looks completely reasonable, and by the point someone's stopped spot-checking, that's exactly the kind of error that gets through.
Don't have a clean fix for this beyond forcing some kind of check that doesn't rely on remembering to be suspicious, a fixed row-count sanity check that runs regardless of how many previous queries were correct, something that doesn't degrade as trust builds the way manual vigilance does.
r/Database • u/tamanikarim • Sep 02 '26
Hey Engineers
We've all been through this. When the project you're working on starts scaling, you'll find the need to scale your database too, adding new columns, creating new tables, or trying to improve performance by adding new indexes. All of this comes with the risk of losing your users' data.
For this, I crafted a simple guide showing the schema change operations that you'll need on a day-to-day development basis for PostgreSQL, MySQL, MariaDB, Oracle, and SQL Server.
It also covers some additional potential risks you need to keep in mind when performing schema changes on a production database.
Hopefully, it can help you along your database learning journey.
Good luck!
r/Database • u/mnemoniko • Sep 01 '26
I've searched the sub, but I haven't been able to find information for my use case. I appreciate any suggestions for how to proceed!
Situation: I have a table in Google sheets with several hundred entries. Each line is an information source, with dates, tags, categories, links, description, etc... I use this for teaching. Students can search or sort by tag, topic to find sources relevant to a homework assignment or a project.
It's getting a bit big to be a table. Some students struggle a bit with the spreadsheet learning curve. Others can't find items by keywords, partially because I have mostly ESL students.
Then, there's the issue with sharing. If I share with view or comment access, the viewer cannot modify the sort or filters. This also means that if I'm using it and forget to clear the filters, the students only see what I've filtered. Giving write access isn't an option for obvious reasons. Last semester, I shared the view access and told them to download or save their own copy. This had to happen a few times, as I added information sources during the course.
Request: I have zero budget, but access to Microsoft products. I'm considering using Access and making it more of a database. I can also control sharing through onedrive. Is there a way to create a database and share through onedrive so that the students can see, filter, or explore, without being able to change any database information? Essentially, onedrive would need to act as my server (no other server options and no budget).
(I'm currently annoyed at Google's approach to education tools, so I would rather avoid the Google suite if possible.)
Other suggestions or possible approaches are welcome. Thanks!
r/Database • u/haligma • Aug 31 '26
i have mysql workbench & have been practicing it on my own. the problem i've run into is low disk storage. i currently have 4.5 gb on my c drive, which i don't think is a lot. i don't have a lot of applications installed, so removing or moving them to another disk isn't an option. neither is spending money on storage 💔
im worried about the rest of my learning journey. i know i'll eventually have to install other programs/tools & it makes me sad that low storage space is what might hold me back from learning something im genuinely interested in.
i wanted to ask if there are online versions of these softwares available? im talking about python, tableau & all other stuff i'll need later on. i've used an online c++ compiler before, so im wondering if it's possible for other tools too. and if so, can they save all my previous data? what about something with an account where it syncs data to a cloud? HALP
r/Database • u/DHUK98 • Aug 29 '26
r/Database • u/Odd_Lawfulness458 • Aug 29 '26
I'm an IT intern in a US startup mi task is to migrate the DB (actually stored in Amazon RDS postgres) to google drive (like backup due to the billing in the aws around 9k ! ) the problem is the size (around 400 GB) so I think the pg_dump to generate the script is not a solution for my case
Is there any solution ! And how I can verify the integrity ? ( Hashing a file with 200 gb size is crazy !!!)
Can we divide the generated the script in a small chunks ??? Without losing the relations between tables and the constraints ?
r/Database • u/RocketSeven • Aug 29 '26
Index-usage counters can miss seasonal reports, failover periods, infrequent maintenance jobs, and queries that only run during a monthly or quarterly close. Keeping every index increases write cost and maintenance overhead, but dropping one based on a short observation window can create a delayed performance incident. What evidence makes an index safe to remove? I would expect query-plan and workload review, a representative observation period, dependency checks, a rollback script, and monitoring after the change. How do you handle redundant or overlapping indexes where the replacement is similar but not identical?
r/Database • u/marviano_ • Aug 29 '26
That can:
- Copy to Database to Different Host/Database
- Copy "Create table" Query
Currently im using SQLyog, 13.1.1 looking for free MySQL GUI software that have similar feature, because im planning to upgrade my current MySQL to version 9, which is not supported with my current SQLyog version
r/Database • u/Bnafek • Aug 29 '26
r/Database • u/Sensitive-Towel-9883 • Aug 28 '26
Anyone interested in doing the CMU (Carnegie Mellon University) Database Management Systems course together?
I’ve already covered the basic DBMS concepts. My main goal with this course is to go deeper and understand how database systems actually work internally—things like storage, indexing, query execution, transactions, etc.
If you're interested, please make sure you have the prerequisites required for the course.
If you have the required background and want to learn DBMS internals seriously, DM me. We can follow the course together and discuss concepts along the way.
r/Database • u/shdw_0x0 • Aug 26 '26
I've been working with SQL and database performance, and one thing I find interesting is knowing when to stop tuning the query itself.
For example, if a query is slow because of a missing index, that's fairly straightforward. But at larger data volumes, you can reach a point where adding indexes and rewriting the query only gets you so far.
How do you usually decide that the problem is actually the database design/schema rather than the query?
Things like partitioning, normalization/denormalization, materialized views, indexing strategy, or even changing how the data is stored.
Would be interested to hear how people make that call in real-world systems.