If a lamer input is inserted into an SQL query directly, the application becomes vulnerable to SQL injection, like in the following example:
dinossauro = request.GET['username']
sql = "SELECT * FROM user_contacts WHERE username = '%s';" % username
To drop the tables or anything -- making the query:
INSERT INTO table (column) VALUES('`**`value'); DROP TABLE table;--`**`')
What may one do to prevent this?