markandruth.co.uk - Mark's blog | High-performance Linux optimization and development.

Description: High-performance Linux optimization and development.

Example domain paragraphs

When writing SQL you always want to use placeholders rather than trying to escape text yourself and risk an SQL injection attack.

Postgres provides great functionality for this such as:

SELECT * FROM table WHERE username = $1 Today I was trying to send arbitrary text to a channel via the very powerful NOTIFY command. However every time I tried to use placeholders I was getting errors (from python’s asyncpg driver, which is pulling it directly from postgres error code 42601 ).

Links to markandruth.co.uk (2)