[SQL] Error while vacuumdb

2010-01-20 Thread Otniel Michael
Hi guys, I already vacuumdb postgresql, and i found error : ERROR : failed to re-find parent key in "pg_attribute_relid_attnam_index" What this error about? Anybody know what should i do? Thanks before. -- --- "He who is quick to

[SQL] Ask About SQL

2009-08-19 Thread Otniel Michael
Hi All. Can help to create sql queries for this data : tabel A field1, field2, field3 x1, y1, 5 x1, y2, 1 x2, y1, 2 x2, y3, 4 x1, y3, 4 I want to get 2 record with the max value at field3 for each kombination of field1 : tabel B field1, field2, field3 x1,

[SQL] Ask To Optimize Looping

2009-08-19 Thread Otniel Michael
Hi guys, can anyone help to optimize this loop : for i in select kodedivisi,kodeseksi,kodewip,nobatch,ket1,ket2,ket3,ket4,NILAIPROP as nilaiygdibagi from EDP040_07_23 order by kodedivisi,kodeseksi,kodewip,nobatch,ket1,ket2,ket3,ket4 loop jmlData2 = jmlData2

Re: [SQL] Asking GO on SQL SERVER

2008-04-02 Thread Otniel Michael
_02 Where SESSID = PSess Order By SBMSNM,WASGRPNM,WASTDS; Select '' spEAR470 - 15 = '' || timeofday() into waktu; Raise Notice ''%'',waktu; /* Delete unused data */ Delete from ear470_01 where sessid = Psess; Delete from ear470_02 where sessid =

[SQL] Asking GO on SQL SERVER

2008-04-02 Thread Otniel Michael
Hi All.. Anybody knows what is "GO" (SQL Server) on Postgres? Thanks. -- --- "He who is quick to become angry will commit folly, and a crafty man is hated"

[SQL] Run Function With First Priority

2007-11-20 Thread Otniel Michael
Dear All, How i can run function with first priority on postgres? In my case, when i run function that need a lot of time. Then the other person run the other function, i think my function run on the below priority of the other function. Thanks. -- "He who is quick to become angry will co

Re: [SQL] ERROR: failed to re-find parent key in "pk_ep07"

2007-10-25 Thread Otniel Michael
r? Thanks. Tom Lane <[EMAIL PROTECTED]> wrote: Otniel Michael writes: > When i was vacuum the database, the vacuum if failed. And I get this error. > Any ideas an to fix this? >ERROR: failed to re-find parent key in "pk_ep07" Update to a newer PG version, po

[SQL] ERROR: failed to re-find parent key in "pk_ep07"

2007-10-24 Thread Otniel Michael
When i was vacuum the database, the vacuum if failed. And I get this error. Any ideas an to fix this? ERROR: failed to re-find parent key in "pk_ep07" Thanks before. Note : EP07 is name of tables. -- "He who is quick to become angry will commit folly, and a crafty man is hated"

Re: [SQL] About Div

2006-07-25 Thread Otniel Michael
on? I need function in postgresql for my case.Because my loop is too slow.Btw thanks for your solution.Aaron Bono <[EMAIL PROTECTED]> wrote: On 7/25/06, Otniel Michael <[EMAIL PROTECTED]> wrote: Dear All,I have a problem with this case :I have 10 candy for 7 child (A, B, C, D, E, F,

[SQL] About Div

2006-07-25 Thread Otniel Michael
Dear All,I have a problem with this case :I have 10 candy for 7 child (A, B, C, D, E, F, G).Table X :code   value ---   A    0     B    0     C    0     D    0     E    0     F    0     G   0    And I want divide it with this algo