
                Intuitionistic fuzzy PostgreSQL (IFPG) 1.0
                          Installation guide


    
  Requirements:
    - PostgreSQL source tree and all the utilities needed to build it
    - g++ compiler
    - patch utility
  
  1. Installing IFPG
  
    IFPG should be installed with the script ifpg-install, which accepts two parameters:
the path to PostgreSQL source and the version of PostgreSQL. Example:
    ./ifpg-install /home/myuser/postgresql-8.0.0 8.0.0
  
  
  2. Compiling PostgreSQL
  
    After successful execution PostgreSQL source is patched. Now you should compile
and install PostgreSQL (see PostgreSQL installation guide, usually run configure, gmake and
gmake install in PostgreSQL directory)
    cd /home/myuser/postgresql-8.0.0
    ./configure
    gmake
    su
    gmake install


  3. Now (re)start PostgreSQL. This is typically done with the command:
    
    /etc/init.d/postgresql restart
      or if it isn't started yet:
    /etc/init.d/postgresql start
  
  
  4. Initializing IFPG
    
    IFPG needs to be initialized. Initialization just creates the template database
_ifs_template, which contains the schema _ifs (see documentation). This is done by
running the script ifpg-init, which accepts as a parameter a user with priviledges to
create a database. Example:
    ./ifpg-init postgres
  
  
  5. Fuzzifying an ordinary database
    
    If a database is created preliminary, you can use the script ifpg-fuzzifydb to
make it an intuitionistic fuzzy database (see documentation). The script accepts two
parameters: database name and user name. Example:
    ./ifpg-fuzzifydb dbname postgres

  
  6. Supported PostgreSQL versions:
      
      7.4
      7.4.1
      7.4.2
      7.4.3
      7.4.4
      7.4.5
      7.4.6
      7.4.7
      8.0.0
      8.0.1

  
  7. Using the translator as a separate executable
    
    You can compile the translator as an executable. This is done by running
      make exe
in ifsql/ directory. The created executable ifsql just translates an IFSQL statement
to a regular SQL statement. You should pass as parameter the name of a file, which
contains the IFSQL statement, or type the statement from the console.

  
  8. Using the translator in your own program (e.g. a frontend utility to PostgreSQL)
    
    The header file ifsql/translator.h contains the prototype of translateIFSQL ().
For details on how to use it, see how the file /src/backend/parser/parser.c is patched
in PostgreSQL source. You should also link to your program the library ifsql/SUBSYS.o
