Re: [ADMIN] SqlServer to PostgreSql
--- Luis Felipe Acevedo Fernandez <[EMAIL PROTECTED]> wrote: > Hi! > I triyed to migrate a database from SqlServer to > PostgreSql, but I have a > problem with char or varchar data types cos If I try > to insert or select some > information from a table the program retrieve blank > spaces, my program was > develop in PowerBuilder 7 > > Example If there is a table with a column char(5) > and I insert the word "Hi" > with 2 character when the program try to retrieve > the information > it gets "Hi " > I also encountered the same problem in Oracle when porting char(n) datatypes. Since char(n) datatypes pads the string with spaces until it has n number of characters. What you can do is you can use either ltrim,rtrim in selecting the data from SQL Server, or use the trim() function in the PowerBuilder before inserting it to a postgres database. ludwig __ Do You Yahoo!? Sign up for SBC Yahoo! Dial - First Month Free http://sbc.yahoo.com ---(end of broadcast)--- TIP 5: Have you checked our extensive FAQ? http://www.postgresql.org/users-lounge/docs/faq.html
Re: [ADMIN] Database Diagrams.
--- Geoff <[EMAIL PROTECTED]> wrote: > Sorry if this is a question that has been answered > in some form or another, > but I need to know if there is a toold of some > description that will help me > get a diagram of my 7.2.1 database with the > relationships. -- There is a tool call ERWin (by Platinum software).You can draw you ER Diagram and the program will automatically generate the schema based on the ER diagram you draw. This software is not open source and is not free. -- I think there are free/open source alternatives. Try searching under the category "CASE tool", "ER diagram", etc. -- ludwig __ Do You Yahoo!? Yahoo! Autos - Get free new car price quotes http://autos.yahoo.com ---(end of broadcast)--- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly
Re: [ADMIN] Auto-Commit
--- Roger Mathis <[EMAIL PROTECTED]> wrote: > Hi > > Is there a possibility to shut down the > Auto-Commit-Funktion? > Thanks Use "BEGIN WORK" or "BEGIN TRANSACTION" statement before typing other SQL statements. This will ensure that the database will only commit if you type "COMMIT" ludwig. __ Do You Yahoo!? Yahoo! Autos - Get free new car price quotes http://autos.yahoo.com ---(end of broadcast)--- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])
Re: [ADMIN] Opening 5432 port
--- Benny <[EMAIL PROTECTED]> wrote: > I can't access postegresl via ODBC, because 5432 > port seems to be closed. > How can I open it? --> Try checking your firewall settings (IPChains / IPTables) and see if its blocking port 5432. Hope that helps, ludwig. __ Do you Yahoo!? New DSL Internet Access from SBC & Yahoo! http://sbc.yahoo.com ---(end of broadcast)--- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]
Re: [ADMIN] FATAL 1: configuration file 'postgresql.conf' has wrong permissions
Hi: --- Michiel Lange <[EMAIL PROTECTED]> wrote: > seems like: > there's read/write, write, write access on the file. > I think the others might want to be able to read the > file instead of writing > to it. > > "Andrey Romanchenko" <[EMAIL PROTECTED]> > schreef in bericht > news:a4t5vu$1jt2$1@;jupiter.hub.org... > > hi all! > > > > when I attempt to start postgresql > > i see error message > > > > FATAL 1: configuration file 'postgresql.conf' has > wrong permissions > > > > > > -rw--w--w-1 postgres postgres 3148 Feb 19 > 11:19 postgresql.conf -- Try doing the following: su postgres chmod 600 postgresql.conf Hope that helps, ludwig. __ Do you Yahoo!? New DSL Internet Access from SBC & Yahoo! http://sbc.yahoo.com ---(end of broadcast)--- TIP 4: Don't 'kill -9' the postmaster
[ADMIN] Logging RAISE statement to a logfile aside from syslog
Hi: Is there a way of logging the RAISE statements in a plpgsql function to a logfile (aside from syslog)? I noticed that all RAISE statments are only logged in the syslog. The following is a portion my current configuration related to logging: log_connection = true log_timestamp = true debug_level = 3 syslog = 2 syslog_facility = 'LOCAL0' syslog_ident = 'postgres' I did not raise the log level to 4 since it create large volumes of logfile. The following is the portion of the script that start my postgresql daemon at boot in /etc/rc.d/init.d : start() { su postgres -c "/usr/local/pgsql/bin/pg_ctl start -l /var/log/postgres/postgres.log -D /data 2> /var/log/postgres/postgres.log" } - I noticed that postgres.log does not contain anything when the debug level is at 3. Version : PostgreSQL 7.2.2 on i686-pc-linux-gnu, compiled by GCC 2.96 Platform : Redhat 7.1 Thank you in advance, ludwig __ Do you Yahoo!? New DSL Internet Access from SBC & Yahoo! http://sbc.yahoo.com ---(end of broadcast)--- TIP 5: Have you checked our extensive FAQ? http://www.postgresql.org/users-lounge/docs/faq.html
Re: [ADMIN] how sub queries and joins differs funcationally
Hi shreedhar : --- shreedhar <[EMAIL PROTECTED]> wrote: > Can any body tell that how sub queries and joins > differs funcationally. > Because sub queries taking lot of time than joins. > The following could be the probable reasons: a) Your are using correlated queries - Correlated queries always re-evaluate the sub-query for each row processed. b) You have an IN clause - try using EXISTS clause, since it IN clause doesn't utilize the index when your subquery is another SELECT statement. ludwig. __ Do you Yahoo!? New DSL Internet Access from SBC & Yahoo! http://sbc.yahoo.com ---(end of broadcast)--- TIP 4: Don't 'kill -9' the postmaster
[ADMIN] Error Messages
Hi: I found the following snippets of error messages in the log file of a computer that is running Postgresql-7.2: NOTICE: Message from PostgreSQL backend: The Postmaster has informed me that some other backend died abnormally and possibly corrupted shared memory.I have rolled back the current transaction and am going to terminate your database system connection and exit. Please reconnect to the database system and repeat your query. Is the error message above related to the following error messages below : DEBUG: pq_recvbuf: recv() failed: Connection timed out DEBUG: pq_flush: send() failed: Connection reset by peer DEBUG: pq_recvbuf: unexpected EOF on client connection DEBUG: pq_flush: send() failed: Broken pipe By the way, I didn't issue a kill to the postgreSQL processes so I'm surpise by the "unexpected EOF on client connection". Do I need to upgrade Postgresql? By the way there are some errors if backup a 7.2 db and restore in 7.3 db. In 7.2 you can do something like "SELECT CURRENT_TIMESTAMP()" in a plpgsql function, while this will cause in an error in 7.3. Do I need to change the hardware? ludwig lim __ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com ---(end of broadcast)--- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])
[ADMIN] Stuck Spinlock Error Message
Hi: I notice the following error message in my postgresql log file: FATAL : s_lock (0x401db020) at lwlock.c Stuck spinlock. Aborting Version of my postgresql : PostgreSQL 7.2.3 on i686-pc-linux-gnu compiled by GCC 2.96 Operating System : RedHat 7.1 Thanks in advance, ludwig lim __ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com ---(end of broadcast)--- TIP 9: the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match