From: Peter J. <pj...@wa...> - 2003-11-29 11:14:53
|
Hi All! > > How insert double quotes between simple quotes? > > This SQL Command > > select * from usuarios where band = 'Guns''n''Roses' > > show me a error: > > At this moment, for the limitations on the batch query execution, using > parametrized querys. Wouldn't one of these methods work: (from MSDN) <cite> and can contain any character literal, including escape sequences: string a = "\\\u0066\n"; // backslash, letter f, new line Note The escape code \udddd (where dddd is a four-digit number) represents the Unicode character U+dddd. Eight-digit Unicode escape codes are also recognized: \udddd\udddd. [...] The advantage of @-quoting is that escape sequences are not processed, which makes it easy to write, for example, a fully qualified file name: @"c:\Docs\Source\a.txt" // rather than "c:\\Docs\\Source\\a.txt" To include a double quotation mark in an @-quoted string, double it: @"""Ahoy!"" cried the captain." // "Ahoy!" cried the captain. </cite> I think, the complicated case would be single quotation marks. Regards, Peter Jacobi |