X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 15E49531E0 for ; Tue, 19 Apr 2005 09:25:19 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 52334-04 for ; Tue, 19 Apr 2005 12:25:16 +0000 (GMT) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by svr1.postgresql.org (Postfix) with ESMTP id A7AB752A85 for ; Tue, 19 Apr 2005 09:25:15 -0300 (ADT) Received: from root by ciao.gmane.org with local (Exim 4.43) id 1DNrid-0005cq-Dj for pgsql-sql@postgresql.org; Tue, 19 Apr 2005 14:20:43 +0200 Received: from gateway.mgm-edv.de ([212.18.1.110]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 19 Apr 2005 14:20:43 +0200 Received: from spam_eater by gateway.mgm-edv.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 19 Apr 2005 14:20:43 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-sql@postgresql.org From: Thomas Kellerer Subject: Re: Query about SQL in PostgreSQL Date: Tue, 19 Apr 2005 12:35:52 +0200 Lines: 25 Message-ID: References: <20050419094846.21474.qmail@web50506.mail.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: gateway.mgm-edv.de User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de-AT; rv:1.7.6) Gecko/20050319 Mnenhy/0.6.0.104 X-Accept-Language: de, de-at, en-us, en In-Reply-To: <20050419094846.21474.qmail@web50506.mail.yahoo.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.389 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200504/280 X-Sequence-Number: 21173 On 19.04.2005 11:48 Muhammad Nadeem Ashraf wrote: > Hi, > I am new user of PostGreSQL 8.0.1. While using it i faced following > issue. As SQL is Case insensetive Language So the Uper or Lower cases > are not significant. But while using the database there is problem. > If i Create new Table with name (tblstudent) then upon SQL queries it is > fine to use Select * from tblstudent. However i face probel if i give > the name of table in Capital letters i.e. if the name is (tblStudent) > then upon using Select * from tblStudent, following error is appeard: > ERROR: relation "tblst" does not exist > > And if i use the query Select * from "tblStudent" then it works fine. > > This is how SQL is defined in the ANSI standard. If you use double quotes around your object names, then it's case sensitiv. If you omit the double quotes it's not. General rule: do not use double quotes at all, and your fine (this is true for other DBMS like Oracle and Firebird as well) Thomas