Comment by BatteryMountain

1 month ago

Actually, I have started with it already but is paused, but the approach is to rebuild it from scratch in parallel to our current legacy system and move our staff over to the new completed screens in batches (we have close to 1000 views in our system, 150 background jobs, with about 15 main categories (think organisational sub-divisions)). So as long as we go slow and steady (even with AI) it will work out fine, I expect it will be done in less than 6 months. One month if we rush but we don't want to rush it, as we are moving some things over from MSSQL to Postgres, so slow and steady is the way.

> from MSSQL to Postgres

How's that going? Any lessons learnt you'd be willing to share?

  • Differences: Money/decimals, rounding, case-sensitivity, equality comparisons differences, db/table locks mechanisms, memory/worker management, table/column naming conventions, null fields/columns effects on queries.

    Mmm what else. I prefer postgres so I'm very excited about this. So many foot-guns will no longer haunt us like on MSSQL and less db/table locks to try solve (pessimistic vs optimistic locks). Oh and we are going to save a gross amount of money per year, as we will also be able to switch off a couple of Windows Server VM's in the process. These puppies are costing us a ton (I think about half of our infra bill are licenses...).

    Just create a branch, spin up a test db and try to port a small feature. Its very easy in most cases. Debian + dotnet + postgres = dream team.

  • If you only use MSSQL as a datastore, it's not too bad. If you used all the other features (MSAS/SSIS/etc...), it is much harder. PG also isn't a panacea - you're trading one set of issues for another. The biggest upside is that it's much less expensive :)

  • MSSQL query optimizer is one of the best available. If you have truly insane queries, views needing joins on views and CTEs, etc, you might be surprised at how well SQL Server was handling them versus PostgreSQL.