SQL tips

How to create a table from already existing table ?

CREATE TABLE command is used to initialize a new table. It works pretty well when we create a new table from scratch. However, if we want to clone already existent schema of an existent table, rewriti...

Continue Reading โ†’

How to improve UNION performance?

Recently I was in trouble. My query based on 3 UNIONs became really slow after some days of adding new data. The problem could be in bad distribution but it wasn't. Instead, it was made by the used UN...

Continue Reading โ†’