Home / comp / gb.db / connection / subst 
Previous  Next  Edit  Rename  Undo  Refresh  Search  Administration   
fr  de  es  it  nl  pl  pt  pt_BR  ca  ar  fa  vi  ja  ru  zh  zh_TW  eo 
Documentation
History
 
Connection.Subst (gb.db)
Syntax
FUNCTION Subst ( Format AS String, Arguments AS , ... ) AS String
Creates a SQL sentence by substituting its arguments in a format string.

The &1, &2... patterns inside the Format string are replaced by respectively the SQL representation of the 1st, 2nd... Arguments.

These arguments are quoted according to the underlying database SQL syntax.

Examples

PRINT DB.Subst("WHERE Name = &1 AND Date = &2", "Benoit", Now)

WHERE Name = 'Benoit' AND Date = '2006-02-15 11:51:33.043'