]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Mention other placeholders
authorAndrew M. Kuchling <amk@amk.ca>
Wed, 7 Jun 2006 17:04:01 +0000 (17:04 +0000)
committerAndrew M. Kuchling <amk@amk.ca>
Wed, 7 Jun 2006 17:04:01 +0000 (17:04 +0000)
Doc/lib/libsqlite3.tex

index 512ae8838591da53f8c00f695428c9f97136233f..9545696da8b745941fe64676602ac688b174dd8c 100644 (file)
@@ -47,10 +47,11 @@ variables.  You shouldn't assemble your query using Python's string
 operations because doing so is insecure; it makes your program
 vulnerable to an SQL injection attack.  
 
-Instead, use SQLite's parameter substitution.  Put \samp{?} as a
+Instead, use the DB-API's parameter substitution.  Put \samp{?} as a
 placeholder wherever you want to use a value, and then provide a tuple
 of values as the second argument to the cursor's \method{execute()}
-method.  For example:
+method.  (Other database modules may use a different placeholder,
+such as \samp{\%s} or \samp{:1}.) For example:
 
 \begin{verbatim}    
 # Never do this -- insecure!