The "Wrong" bit is debatable
No, it's just wrong, regarding the quotes. I totally lost the thread context when replying to Re^3: SQL Query error while executing in perl. Is it possible to execute these Scripts??. All that I wanted to comment was the possible SQL injection ...
my $sql = "DECLARE \@log varchar(5) SET \@log=$tim Update dbo.tltime s +et logtime = \@log"; # ... here --^
... combined with the words "so , use double-quotes", this lead to ...
my $sql = "DECLARE \@log varchar(5) SET \@log=\"$tim\" Update dbo.tlti +me set logtime = \@log"; # ^^ ^^
... in my mind. Which is even worse than what was posted. This lead to my "Wrong." posting. Still, at least MySQL allows values in double quotes, unless ANSI QUOTES are enabled.
Regarding problems with quoted identifiers, you are right. Quoting identifiers can cause more problems than it is worth.
Alexander
In reply to Re^6: SQL Query error while executing in perl. Is it possible to execute these Scripts??
by afoken
in thread SQL Query error while executing in perl. Is it possible to execute these Scripts??
by Sachin_dada
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |