X-Original-To: pgsql-docs-postgresql.org@localhost.postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id B6BCC9FA169 for ; Tue, 23 May 2006 15:09:14 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 16215-04-2 for ; Tue, 23 May 2006 15:08:59 -0300 (ADT) X-Greylist: delayed 00:05:02.034903 by SQLgrey- Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.171]) by postgresql.org (Postfix) with ESMTP id B280A9FA634 for ; Tue, 23 May 2006 15:08:59 -0300 (ADT) Received: from [84.163.125.185] (helo=dslrouter.ctilabs.internal) by mrelayeu.kundenserver.de (node=mrelayeu5) with ESMTP (Nemesis), id 0ML25U-1FibEZ1sNV-0008QD; Tue, 23 May 2006 20:03:55 +0200 Received: from inari.ctilabs.internal ([192.168.1.95] ident=Debian-exim) by dslrouter.ctilabs.internal with esmtp (Exim 4.50 #1 (Debian)) id 1FibEY-0000mJ-Gm for ; Tue, 23 May 2006 20:03:54 +0200 Received: from run by inari.ctilabs.internal with local (Exim 4.50 #1 (Debian)) id 1FibEY-0000tE-BJ for ; Tue, 23 May 2006 20:03:54 +0200 Date: Tue, 23 May 2006 20:03:54 +0200 To: pgsql-docs@postgresql.org Subject: Pattern with backslash commands in psql terminal Message-ID: <20060523180354.GA3057@inari.ctilabs.internal> Reply-To: rolf.unger@ctilabs.de Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.9i From: Rolf Unger X-Provags-ID: kundenserver.de abuse@kundenserver.de login:686d32649f76a67c0ed3ccbc4711a7a4 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200605/42 X-Sequence-Number: 3569 Hi Folks, actually I am not sure if this is the right mailing list, although I am quite sure that this is a documenation issue: I want to list the functions that are defined in a database and tried to use the internal \df command of the psql terminal (I use emacs so I don't need pgAdmin). Of course I don't want to see all internal function like substr(), cast(), ..., but only those that were created by myself some weeks ago. The internal docs say that I can specify an optional pattern after the \df or the \df+. And I think I read somewhere that the pattern is meant to be a regular expression. So wildcards should rather be .* or [a-z]+ and not the typical shell wildcards ? or *. But I had no success in either way. And using SQL wildcards % or _ doesn't work as well. "No success" means: The returned list is empty. And I didn't find more detailed information anywhere in the docs. Only if I use the full function name as pattern, then one row with the function is returned. But that is useless, because my starting point is usually: "What's the exact name of this function again? It started with 'my_' but was it 'export' or 'exp' after the prefix?" \df my_ --> no rows \df "my_.*" --> no rows \df /my_.*/ --> no rows \df "my_*" --> no rows \df 'my%' --> no rows \df my_export --> (1 row) Are there some special delimiters required? It would be really a good thing to have at least a comment or a footnote with any one of the \d commands what kind of syntax is needed for the [PATTERN]. An example would surely be a good idea as well. Thanks, Rolf.