lang | title | author | description | keywords |
---|---|---|---|---|
en-GB |
SQL Notes |
Jerry Sky |
Notes on SQL-related stuff. |
notes, SQL, query, database |
GROUP_CONCAT
andDISTINCT
- Replacing
NULL
with a different value - Pivoting in MySQL
- Performance tuning — Query Caching
- TypeORM — Databases with TypeScript
-- create a temporary table
CREATE TEMPORARY TABLE exportTable AS (your_query);
-- show the columns
SHOW COLUMNS FROM exportTable;
SET FOREIGN_KEY_CHECKS = 0;
truncate table "yourTableName";
SET FOREIGN_KEY_CHECKS = 1;
A data set of 9 million tuples is nothing for a relational database. For maintaining sufficient performance as always use indexes and all will be well.