Add new FAQ information.
authorBruce Momjian
Wed, 10 Aug 2005 19:30:05 +0000 (19:30 +0000)
committerBruce Momjian
Wed, 10 Aug 2005 19:30:05 +0000 (19:30 +0000)
Martijn van Oosterhout

doc/FAQ
doc/src/FAQ/FAQ.html

diff --git a/doc/FAQ b/doc/FAQ
index d7e2d5ea59695e367a9dc64eeff5770562194d8d..e1c3cf1999abedc644eb6030192c70297c757e5b 100644 (file)
--- a/doc/FAQ
+++ b/doc/FAQ
@@ -1,7 +1,7 @@
 
                 Frequently Asked Questions (FAQ) for PostgreSQL
                                        
-   Last updated: Fri Jul 29 10:05:09 EDT 2005
+   Last updated: Wed Aug 10 15:29:42 EDT 2005
    
    Current maintainer: Bruce Momjian ([email protected])
    
@@ -79,6 +79,7 @@
    4.19) Why do I get "relation with OID ##### does not exist" errors
    when accessing temporary tables in PL/PgSQL functions?
    4.20) What replication solutions are available?
+   4.21) Why are my table and column names not recognized in my query?
      _________________________________________________________________
    
                              General Questions
    The maximum table size and maximum number of columns can be quadrupled
    by increasing the default block size to 32k.
    
+   One limitation is that indexes can not be created on columns longer
+   than about 2,000 characters. Fortunately, such indexes are rarely
+   needed. Uniqueness is best guaranteed using another column that is an
+   MD5 hash of the long column, and full text indexing allows for
+   searching of words within the column.
+   
   4.5) How much database disk space is required to store data from a typical
   text file?
   
    expresssion index, it will be used:
     CREATE INDEX tabindex ON tab (lower(col));
 
+   If the above index is created as UNIQUE, though the column can store
+   upper and lowercase characters, it can not have identical values that
+   differ only in case. To force a particular case to be stored in the
+   column, use a CHECK constraint or a trigger.
+   
   4.9) In a query, how do I detect if a field is NULL? How can I sort on
   whether a field is NULL or not?
   
    
    There are also commercial and hardware-based replication solutions
    available supporting a variety of replication models.
+   
+  4.20) Why are my table and column names not recognized in my query?
+  
+   The most common cause is the use of double-quotes around table or
+   column names during table creation. When double-quotes are used, table
+   and column names (called identifiers) are stored case-sensitive,
+   meaning you must use double-quotes when referencing the names in a
+   query. Some interfaces, like pgAdmin, automatically double-quote
+   identifiers during table creation. So, for identifiers to be
+   recognized, you must either:
+     * Avoid double-quoting identifiers when creating tables
+     * Use only lowercase characters in identifiers
+     * Double-quote identifiers when referencing them in queries
index 71e659db94d43ae458bd92482f3add1bbfd14cb4..07dd956e2ef74e44084efb970f2a3d40350c7a0b 100644 (file)
@@ -10,7 +10,7 @@
   alink="#0000ff">
     

Frequently Asked Questions (FAQ) for PostgreSQL

 
-    

Last updated: Mon May 30 09:11:03 EDT 2005

+    

Last updated: Wed Aug 10 15:29:42 EDT 2005

 
     

Current maintainer: Bruce Momjian (

@@ -26,7 +26,7 @@
     
 
     General Questions
-    1.1) What is PostgreSQL? How is it pronounced?
+     1.1) What is PostgreSQL? How is it pronounced?
      1.2) What is the copyright of PostgreSQL?
      1.3) What platforms does PostgreSQL support?
      1.4) Where can I get PostgreSQL?
     does not exist" errors when accessing temporary tables in PL/PgSQL
     functions?
      4.20) What replication solutions are available?
-     
+     4.21) Why are my table and column names not
+    recognized in my query?
+
 
     
 
 
     

1.1) What is PostgreSQL? How is it pronounced?

 
-    

PostgreSQL is pronounced Post-Gres-Q-L, also called just

-    Postgres.

+    

PostgreSQL is pronounced Post-Gres-Q-L, and is also sometimes 

+    referred to as just Postgres. An audio file is available in 
+    MP3 format for 
+    those would like to hear the pronunciation.

 
     

PostgreSQL is an object-relational database system that has the

     features of traditional commercial database systems with
@@ -613,6 +617,12 @@ table?unlimited
     

The maximum table size and maximum number of columns can be

     quadrupled by increasing the default block size to 32k.

 
+    

One limitation is that indexes can not be created on columns

+    longer than about 2,000 characters. Fortunately, such indexes are
+    rarely needed. Uniqueness is best guaranteed using another column
+    that is an MD5 hash of the long column, and full text indexing
+    allows for searching of words within the column.

+
     

4.5) How much database disk space is required

     to store data from a typical text file?
 
@@ -740,7 +750,12 @@ table?unlimited
 
     CREATE INDEX tabindex ON tab (lower(col));
 
-
+    

If the above index is created as UNIQUE, though

+    the column can store upper and lowercase characters, it can not have
+    identical values that differ only in case. To force a particular
+    case to be stored in the column, use a CHECK
+    constraint or a trigger.

+                    
     

4.9) In a query, how do I detect if a field

     is NULL?  How can I sort on whether a field is 
     NULL or not?
@@ -1000,5 +1015,22 @@ length
 
     

There are also commercial and hardware-based replication solutions

     available supporting a variety of replication models.

+
+    

4.20) Why are my table and column names not

+    recognized in my query?
+
+    

The most common cause is the use of double-quotes around table or

+    column names during table creation. When double-quotes are used,
+    table and column names (called identifiers) are stored 
+    href="http://www.postgresql.org/docs/8.0/static/sql-syntax.html#SQL-
+    SYNTAX-IDENTIFIERS">case-sensitive, meaning you must use
+    double-quotes when referencing the names in a query. Some interfaces,
+    like pgAdmin, automatically double-quote identifiers during table
+    creation. So, for identifiers to be recognized, you must either:
+    
    +    
  • Avoid double-quoting identifiers when creating tables
  • +    
  • Use only lowercase characters in identifiers
  • +    
  • Double-quote identifiers when referencing them in queries
  • +