Thread

  1. Backend=UNICODE,client=WIN-1250 - impossible

    Olaf Frączyk <olaf@cbk.poznan.pl> — 2002-06-11T15:10:13Z

    Hi,
    In multibyte manual is a table of possible encodings used by postgresql.
    But there is also a table o possible recodings, and if I have data
    stored as UNICODE, there is not listed WIN-1250 as client encoding.
    Is this documentation bug, or is it really impossible. If it is
    impossible, when will it be supported?
    Or maybe there is another way to get unicode data from postgres to
    display on windows correctly?
    Now I have data stored as iso-8859-2 but I want to use unicode.
    
    Please CC me.
    
    Regards,
    
    Olaf Fraczyk
    
    
    
    
    
    
    
    
    
  2. View String or Representation

    SERFIOTIs gewrgios <serfioti@csd.uoc.gr> — 2002-06-11T15:55:24Z

    Hi,
    	does anyone know when I create a view where does Postgresql
    store the string with the view definition or any other internal
    representation of the view?
    
    I have looked up for the question in two Postgresql manual without finding
    an answer!
    
    Thank you,
    George.
    
    
    
    
  3. Re: View String or Representation

    Gregory Seidman <gss+pg@cs.brown.edu> — 2002-06-11T16:11:49Z

    SERFIOTIs gewrgios sez:
    } 	does anyone know when I create a view where does Postgresql
    } store the string with the view definition or any other internal
    } representation of the view?
    } 
    } I have looked up for the question in two Postgresql manual without finding
    } an answer!
    
    If you use psql, you can type \d <viewname> to get the definition of the
    view. If you start psql with the -E and type that you will see the SQL that
    psql is invoking to find the information, including the reference to the
    pg_views system table.
    
    } Thank you,
    } George.
    --Greg
    
    
    
  4. Re: View String or Representation

    scott.marlowe <scott.marlowe@ihs.com> — 2002-06-11T16:24:41Z

    Try looking in pg_views (I'm on 7.2) for more info.
    
    \dS shows you all the system tables that are normally hidden.
    
    On Tue, 11 Jun 2002, SERFIOTIs gewrgios wrote:
    
    > Hi,
    > 	does anyone know when I create a view where does Postgresql
    > store the string with the view definition or any other internal
    > representation of the view?
    > 
    > I have looked up for the question in two Postgresql manual without finding
    > an answer!
    > 
    > Thank you,
    > George.
    > 
    > 
    > 
    > ---------------------------(end of broadcast)---------------------------
    > TIP 3: if posting/reading through Usenet, please send an appropriate
    > subscribe-nomail command to majordomo@postgresql.org so that your
    > message can get through to the mailing list cleanly
    > 
    
    
    
  5. Re: View String or Representation

    SERFIOTIs gewrgios <serfioti@csd.uoc.gr> — 2002-06-11T16:28:25Z

    Thanks,
    	I have read about this option, but i need to access the view definition
    through JDBC, so i need a 'SELECT' statement that can be executed by JDBC.
    
    George.
    
    On Tue, 11 Jun 2002, Gregory Seidman wrote:
    
    > SERFIOTIs gewrgios sez:
    > } 	does anyone know when I create a view where does Postgresql
    > } store the string with the view definition or any other internal
    > } representation of the view?
    > }
    > } I have looked up for the question in two Postgresql manual without finding
    > } an answer!
    >
    > If you use psql, you can type \d <viewname> to get the definition of the
    > view. If you start psql with the -E and type that you will see the SQL that
    > psql is invoking to find the information, including the reference to the
    > pg_views system table.
    >
    > } Thank you,
    > } George.
    > --Greg
    >
    >
    > ---------------------------(end of broadcast)---------------------------
    > TIP 4: Don't 'kill -9' the postmaster
    >
    
    
    
  6. Re: View String or Representation

    Jan Wieck <janwieck@yahoo.com> — 2002-06-11T16:56:09Z

    Gregory Seidman wrote:
    > SERFIOTIs gewrgios sez:
    > }  does anyone know when I create a view where does Postgresql
    > } store the string with the view definition or any other internal
    > } representation of the view?
    > }
    > } I have looked up for the question in two Postgresql manual without finding
    > } an answer!
    >
    > If you use psql, you can type \d <viewname> to get the definition of the
    > view. If you start psql with the -E and type that you will see the SQL that
    > psql is invoking to find the information, including the reference to the
    > pg_views system table.
    
        pg_views isn't a system table at all! It is a view itself :-)
    
        This system view is calling a function that reconstructs  the
        view  definition  from  the information stored in pg_rewrite,
        which is an ASCII representation of  the  internal  parsetree
        format of a query rewrite rule.
    
    
    Jan
    
    --
    
    #======================================================================#
    # It's easier to get forgiveness for being wrong than for being right. #
    # Let's break this rule - forgive me.                                  #
    #================================================== JanWieck@Yahoo.com #
    
    
    
    
  7. Acquiring views

    SERFIOTIs gewrgios <serfioti@csd.uoc.gr> — 2002-06-12T14:01:55Z

    Hi,
    	i'm using the function getTables() of interface DatabaseMetaData
    trying to obtain the names of the views which are defined in the database.
    However, although it works with an Oracle Database, it doesn't work in a
    Postgresql Database.
    The exact statement i'm using is the following:
    String types[] = new String[1];
    types[0] = new String("VIEW");
    ResultSet rs = this.dbmd.getTables(null, null, null, types);
    
    The result is that I get java.lang.NullPointerException at the last line,
    although I do have a view declared!
    
    When I'm using: types[0] = new String("TABLE") instead it works fine. Is
    there a problem between what PostgreSQL considers a view, and what JDBC
    considers a view?
    
    Thank you.
    
    
    
  8. Re: Acquiring views

    Barry Lind <barry@xythos.com> — 2002-06-13T05:01:01Z

    What version of the driver are you using?  I am unable to reproduce the 
    problem with the latest driver.
    
    --Barry
    
    SERFIOTIs gewrgios wrote:
    > Hi,
    > 	i'm using the function getTables() of interface DatabaseMetaData
    > trying to obtain the names of the views which are defined in the database.
    > However, although it works with an Oracle Database, it doesn't work in a
    > Postgresql Database.
    > The exact statement i'm using is the following:
    > String types[] = new String[1];
    > types[0] = new String("VIEW");
    > ResultSet rs = this.dbmd.getTables(null, null, null, types);
    > 
    > The result is that I get java.lang.NullPointerException at the last line,
    > although I do have a view declared!
    > 
    > When I'm using: types[0] = new String("TABLE") instead it works fine. Is
    > there a problem between what PostgreSQL considers a view, and what JDBC
    > considers a view?
    > 
    > Thank you.
    > 
    > 
    > ---------------------------(end of broadcast)---------------------------
    > TIP 2: you can get off all lists at once with the unregister command
    >     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)
    >