Vote count:
0
When inserting into MySQL with PHP, I can do either of the following:
$query = 'INSERT INTO tablename SET id = "4"';
$query = "INSERT INTO tablename SET id = '4'";
$query = 'INSERT INTO tablename SET id = \'4\'';
$query = "INSERT INTO tablename SET id = \"4\"";
Is there a reason (security, performance, code readability, ...) why I should prefer one of them?
asked 2 mins ago
Aucun commentaire:
Enregistrer un commentaire