Returns the quoted version of a string.
Unit
SysUtils
Category
String handling routines
Delphi syntax:
function QuotedStr(const S: string): string;
Description
Use QuotedStr to convert the string S to a quoted string. A single quote character (‘) is inserted at the beginning and end of S, and each single quote character in the string is repeated.
Note: When working with multi-byte character systems (MBCS), use AnsiQuotedStr instead.
Example
SQL.Add(format( ‘select * from tabname where field1 = %s’, [QuotedStr(Edit1.Text)]));
转载于:https://www.cnblogs.com/gleam/archive/2008/12/11/1352580.html
发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/183628.html原文链接:https://javaforall.net