0

I've worked on a car dealership for a year now and most of my time is spent automating business reports and spreadsheets from their ERP/CRM or fixing issues related to them since it's a pretty bad system with a lot of flaws.

Thanks to that, I've been slowly designing a new web and mobile app that basically works as addon to ERP's in order to have better automated and customizable reports, but it's my first time actually designing a database.

While looking at the old ERP for reference, I've noticed that certain columns are redundant (such as a profit margin column on the vehicles table, data that could be obtained by just comparing the costs vs the sale profit) and I wonder if the reason for that wasn't reducing query times/server load since it uses 3 tables for that calculation (entry, exit and the vehicle).

To me it sounds really bad to leave this redundant data as it could cause inconsistencies, but I don't know how much it would actually affect server performance in a day-to-day basis for low-end servers and the fact that a relatively big ERP company just left that in makes me wonder if I should try doing something similar.

  • You give them too much credit. Do what you need to do and don't look on big ERP systems - most likely these are leftovers that they did not have a chance/budget to clean up. – trailmax Feb 25 '20 at 01:19
  • This kind of redundancy can be avoided by proper use of caching (at application level). For example, the first time that someone requests the markup, you calculate it using that probably slow query, and save the value. Next times you will have the value cached with very fast performance. The downside is that you will need to flush cache everytime that a price changes for example, or assume that your markup might be outdated (by the maximum duration of your cache). That's a choice that you will need to do. – Elias Soares Feb 25 '20 at 01:23

0 Answers0