Vivian Zhang

Lessons Learned: Handling DateTime Across Time Zones in Postgres with SQLAlchemy and Alembic

Working with date and time in a global application is tricky. When you throw in multiple time zones, daylight saving time (DST), and different database behaviors, things can get messy quickly. Here’s what I learned while working with Python, SQLAlchemy, Alembic, and PostgreSQL. Lesson 1 — Always Use TIMESTAMP WITH TIME ZONE in Postgres In PostgreSQL, there are two main timestamp types: Rule: Use timestamptz for anything that needs to

Running Flash App after EOL with Electron

Many companies using Flash in their websites are facing this problem because of Adobe Flash Player end-of-life (EOL). One solution is to build a new website to replace the Flash based website using modern web technologies like HTML5, CSS and JaveScripts. But if for any reason, this cannot be done before the EOL date, which is end of 2020, I have tested a workaround solution which can ‘extend’ Flash Player’s

Access Existing MySQL Database with Entity Framework Core

In this article, I will explain step by step how to connect to an existing MySQL database in a ASPNET web application using Entity Framework (EF) Core. This process is described by Microsoft as Reverse Engineering as opposed to the Migration process. In short, you use Migration when you start building a new application from scratch including the database; and you use Reverse Engineering when you build your application using