Re: [GENERAL] about scape characters

2010-07-14 Thread Kenichiro Tanaka
Hello I've used oracle for 10years,but I've never seen such notations. In fact the SQL retuns an error . postgres=# select E'\\'; ?column? -- \ (1 row) SQL> select E'\\' from dual; select E'\\' from dual * ERROR at line 1: ORA-00923: FROM keyword not found where expected

Re: [GENERAL] getting the last N tuples of a query

2010-07-08 Thread Kenichiro Tanaka
Hello. I agree Ben. But,I try your question as an SQL puzzle. Doses this SQL meet what you want? select * from wantlast offset (select count(*)-10 from wantlast); --test case create table wantlast(col1 int); insert into wantlast select g from generate_series(1,1000) as g; postgres=# select * f

Re: [GENERAL] SQL error: could not connect to database

2010-06-23 Thread Kenichiro Tanaka
Hi. At first,I think you lack some settings. (eg. pg_hba.conf,listen_addresses or restarting) But you say "I can log in to postgresql without password prompt using the psql tool". I can image some case,but we have to get some more information. So I'd like you to try the following program.This

Re: [GENERAL] WINDOWS : PostgreSQL 8.4 Server Start Error

2010-06-07 Thread Kenichiro Tanaka
hing useful there. I wouldn't be too surprised to find that PowerDVD has installed something it shouldn't into C:\WINDOWS\SYSTEM32. -- Craig Ringer -- ==== Kenichiro Tana

Re: [GENERAL] archive_command

2010-05-31 Thread Kenichiro Tanaka
Hello In my environment,archive_command works fine with this command. archive_command = 'COPY %p C:\\Program Files\\PostgreSQL\\8.4\\data\\archive\\%f' (Is this what you want to know?) > Where can I find an example shell script and windows batch file for > archive_command for backup? > > Tha

Re: [GENERAL] Help on update.

2010-05-26 Thread Kenichiro Tanaka
) y where x.i = y.i and x.j = y.j) how can translate this for work in postgres? Thanks's Paul | Paulo -- Kenichiro Tanaka K.K.Ashisuto http://www.ashisuto.co.jp/english/index

Re: [GENERAL] effective_io_concurrency details

2010-05-26 Thread Kenichiro Tanaka
1 Postgres 8.4.4 pasman -- ======== Kenichiro Tanaka K.K.Ashisuto http://www.ashisuto.co.jp/english/index.html -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] cleaning wal files from postgres

2010-05-24 Thread Kenichiro Tanaka
dreas -- Kenichiro Tanaka K.K.Ashisuto http://www.ashisuto.co.jp/english/index.html -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] How to deal with NULL values on dynamic queries?

2010-05-06 Thread Kenichiro Tanaka
|| quote_literal(pVAL_CAMPO1) || ', ' || quote_literal(pVAL_COMENT) || ')'; [/code] The variable pVAL_COMENT could be NULL or have a value. How can I deal with this? Sorry the bad english. Best Regards, -- =

Re: [GENERAL] Select with string that has a lone hyphen yields nothing

2010-04-30 Thread Kenichiro Tanaka
gital Camera - Blue %%'; product_id | name +-- (0 rows) Any ideas how to fix this? -- ==== Kenichiro Tanaka K.K.Ashisuto http://www.ashisuto.co.jp/english/index.html -- Sent via pgsql-gene

Re: [GENERAL] pg_hba.conf

2010-04-27 Thread Kenichiro Tanaka
FATAL: no pg_hba.conf entry for host "209.159.145.248", user "postgres", database "arc" pg_hba.conf contains the line: hostall all209.159.145.248 255.255.255.255 trust Would there be a line earlier in the file that matches and is preven

Re: [GENERAL] gmake check problem

2010-04-27 Thread Kenichiro Tanaka
$ Any help would be appreciated. Thanks, Jim -- ======== Kenichiro Tanaka K.K.Ashisuto http://www.ashisuto.co.jp/english/index.html -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To

Re: [GENERAL] Problem with pg_prepare

2010-04-26 Thread Kenichiro Tanaka
s about how to fix it. Any suggestions? Thank you. -- ======== Kenichiro Tanaka K.K.Ashisuto http://www.ashisuto.co.jp/english/index.html -- Sent via pgsql-general mailing list (pgsql-gen

Re: [GENERAL] Need some help with a query (uniq -c)

2010-04-13 Thread Kenichiro Tanaka
--- a | 1 |1 | 1 b | 2 |4 | 3 a | 5 |5 | 1 That'll only work if the time values are contiguous, but there's probably a similar trick for non-contiguous. Cheers, Steve --

Re: [GENERAL] when i logged in mydb,any sql command used to list all the tables in this mydb?

2010-04-08 Thread Kenichiro Tanaka
ll the databases,how do the postgresql interval implement it? will the postgresql interval load all the pg_ tables in all the databases to get the final answer? Thanks! peng 2010/4/8 Kenichiro Tanaka <mailto:ketan...@ashisuto.co.jp>> Hello sunpeng First,I answer this

Re: [GENERAL] when i logged in mydb,any sql command used to list all the tables in this mydb?

2010-04-08 Thread Kenichiro Tanaka
re no database( pg_database.oid) field in pg_class table,so i can not use select relname from pg_class,pg_database where pg_database.datname like 'mydb' and pg_class.database = pg_database.oid; anybody knows how to do it? another question:how postgresql internal kno

Re: [GENERAL] How to fix set-valued function called in context that cannot accept a set in earlier versions

2010-04-05 Thread Kenichiro Tanaka
;; END IF ; if res<>'' then res := res || ' '; end if; res := res || words[i]; end loop; return next res; END $$ LANGUAGE plpgsql; select wordwrap('fdgdf',10) -- Kenichiro Tanaka K.K.Ashisuto h