summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorD'Arcy J.M. Cain2007-10-01 19:06:48 +0000
committerD'Arcy J.M. Cain2007-10-01 19:06:48 +0000
commit7b04180cf51cdfa9ebf44d03febe1d359b341e8a (patch)
tree55515d0db701a58838ad908d8a26b1643f3535dc
parenta78a854e615d7191f27b415d806ff6132b962f25 (diff)
Add some examples.
-rw-r--r--contrib/chkpass/README.chkpass30
1 files changed, 30 insertions, 0 deletions
diff --git a/contrib/chkpass/README.chkpass b/contrib/chkpass/README.chkpass
index 0ebc4d7980..9f8e100622 100644
--- a/contrib/chkpass/README.chkpass
+++ b/contrib/chkpass/README.chkpass
@@ -21,6 +21,36 @@ The encryption uses the standard Unix function crypt(), and so it suffers
from all the usual limitations of that function; notably that only the
first eight characters of a password are considered.
+Here is some sample usage:
+
+test=# create table test (p chkpass);
+CREATE TABLE
+test=# insert into test values ('hello');
+INSERT 0 1
+test=# select * from test;
+ p
+----------------
+ :dVGkpXdOrE3ko
+(1 row)
+
+test=# select raw(p) from test;
+ raw
+---------------
+ dVGkpXdOrE3ko
+(1 row)
+
+test=# select p = 'hello' from test;
+ ?column?
+----------
+ t
+(1 row)
+
+test=# select p = 'goodbye' from test;
+ ?column?
+----------
+ f
+(1 row)
+
D'Arcy J.M. Cain