Mention that LIKE ... ESCAPE '' is allowed to specify no
authorTom Lane
Sun, 18 Nov 2001 21:17:10 +0000 (21:17 +0000)
committerTom Lane
Sun, 18 Nov 2001 21:17:10 +0000 (21:17 +0000)
escape character.

doc/src/sgml/func.sgml

index b03a8b28ee3580cb9d1fb0d93309818966839fe8..b1c9503705f7245521f09fdebd0d991e65d065b8 100644 (file)
@@ -1,5 +1,5 @@
 
 
@@ -1228,8 +1228,19 @@ Postgres documentation
    
     Note that the backslash already has a special meaning in string
     literals, so to write a pattern constant that contains a backslash
-    you must write two backslashes in the query.  You can avoid this by
-    selecting a different escape character with ESCAPE.
+    you must write two backslashes in the query.  Thus, writing a pattern
+    that actually matches a literal backslash means writing four backslashes
+    in the query.  You can avoid this by selecting a different escape
+    character with ESCAPE; then backslash isn't special
+    to LIKE anymore. (But it's still special to the string
+    literal parser, so you still need two of them.)
+   
+
+   
+    It's also possible to select no escape character by writing
+    ESCAPE ''.  In this case there is no way to
+    turn off the special meaning of underscore and percent signs in
+    the pattern.
    
 
    
@@ -1245,7 +1256,7 @@ Postgres documentation
     ILIKE.  There are also
     !~~ and !~~* operators that
     represent NOT LIKE and NOT
-    ILIKE.  All of these are also
+    ILIKE.  All of these operators are
     Postgres-specific.