[GENERAL] noobie join question

2015-05-11 Thread Steve Clark
Hi List, I am having trouble trying to figure out how to get the result listed at the bottom. I have 3 tables units, types of units which has a description of the units, and a table that list associations of the units. I can't figure out how to do the proper joins. Any pointers would be

[GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Daniel Begin
I am working on windows and I had to move my database on another hard drive after the original one started overheating. In order to move the DB I did the following. -Stop postgresql-x64-9.3 service - and wait until there were no more system access to on the original drive -Copy the entire

Re: [GENERAL] noobie join question

2015-05-11 Thread Oliver Elphick
On Mon, 2015-05-11 at 06:46 -0400, Steve Clark wrote: Hi List, I am having trouble trying to figure out how to get the result listed at the bottom. I have 3 tables units, types of units which has a description of the units, and a table that list associations of the units. I can't figure out

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Raymond O'Donnell
On 11/05/2015 12:03, Daniel Begin wrote: I am working on windows and I had to move my database on another hard drive after the original one started overheating. In order to move the DB I did the following… -Stop postgresql-x64-9.3 service – and wait until there were no more system

[GENERAL] Comparing txid and xmin (under BDR)

2015-05-11 Thread Peter Mogensen
Hi, I would really like to be able to externally to Postgres at some point in time later, be able to compare the txid of 2 queries. Namely: The INSERT transaction for a certain row in a table, and The SELECT transaction reading some other data. With the one caveat that this has to work with

Re: [GENERAL] noobie join question

2015-05-11 Thread Albe Laurenz
Steve Clark wrote: I am having trouble trying to figure out how to get the result listed at the bottom. That's a bit tough, since you don't describe the desired result. I have 3 tables units, types of units which has a description of the units, and a table that list associations of the

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Daniel Begin
I just get it back running with the old drive - was some Windows hidden behavior! However, does someone could tell me what went wrong with the procedure I used to move the DB? And/or what procedure I should have used in order to get it right? Daniel -Original Message- From: Raymond

Re: [GENERAL] noobie join question

2015-05-11 Thread Steve Clark
On 05/11/2015 07:16 AM, Oliver Elphick wrote: On Mon, 2015-05-11 at 06:46 -0400, Steve Clark wrote: Hi List, I am having trouble trying to figure out how to get the result listed at the bottom. I have 3 tables units, types of units which has a description of the units, and a table that list

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Raymond O'Donnell
On 11/05/2015 13:38, Daniel Begin wrote: I just get it back running with the old drive - was some Windows hidden behavior! However, does someone could tell me what went wrong with the procedure I used to move the DB? And/or what procedure I should have used in order to get it right? I've

Re: [GENERAL] How to clean/truncate / VACUUM FULL pg_largeobject without (much) downtime?

2015-05-11 Thread Francisco Olarte
Hi Muthusamy: On Mon, May 11, 2015 at 11:48 AM, Muthusamy, Sivaraman sivaraman.muthus...@in.verizon.com wrote: With regards to this pg_largeobject, I have the following questions: - What is this pg_largetobject ? Just seeking it in the alpha index leads you here:

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Daniel Begin
Thank for the link! Just to make sure I understand properly... When I installed Postgresql, I set $PGDATA to point on my old drive and I must now move everything on the new one. In order to move everything on the new drive I must create a tablespace on the new drive and then explicitly define

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Francisco Olarte
( OOps, forgot to cc the list again in previous, quoting all message for context ). On Mon, May 11, 2015 at 3:14 PM, Daniel Begin jfd...@hotmail.com wrote: Makes sense considering the error message! Maybe an image backup would make the job... I do not know how they are, made in windows, but

[GENERAL] How to clean/truncate / VACUUM FULL pg_largeobject without (much) downtime?

2015-05-11 Thread Muthusamy, Sivaraman
Hi Group, Facing a problem where pg_catalog.pg_largetobject has been growing fast recently, in last two weeks. The actual data itself, in user tables, is about 60GB, but pg_catalog.pg_largeobject table is 200GB plues. Please let me know how to clean/truncate this table without losing any user

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Francisco Olarte
Hi Daniel. On Mon, May 11, 2015 at 4:42 PM, Daniel Begin jfd...@hotmail.com wrote: Just to make sure I understand properly... When I installed Postgresql, I set $PGDATA to point on my old drive and I must now move everything on the new one. In order to move everything on the new drive I must

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Daniel Begin
Francisco wrote: How big/critical is your database? How big? According to PgAdmin my personal database is about 2TB... How critical? Well, about a year of work!-) Francisco wrote: just did a stop/cp/change pgdata /restart, I suppose windows must have comparable ways This is what I have just

Re: [GENERAL] Why does this SQL work?

2015-05-11 Thread Victor Yegorov
2015-05-11 19:26 GMT+03:00 Anil Menon gakme...@gmail.com: manualscan= select count(*) From public.msgtxt where msgid in (select msgid From ver736.courier where org_id=3); count --- 10225 (1 row) Please note, there is no msgid col in courier table. Which brings the question why does

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Daniel Begin
Interesting, The symbolic links on the old drive -still used by the DB- look like windows' shortcuts to parent folder, while they are empty folders in the copy of the database I have on the new drive... When I do a plane copy of those links on another drive I also get the same empty folders. I

Re: [GENERAL] Why does this SQL work?

2015-05-11 Thread hubert depesz lubaczewski
On Tue, May 12, 2015 at 12:26:15AM +0800, Anil Menon wrote: manualscan= select count(*) From msgtxt where msgid in ( manualscan( select msgid From courier where org_id=3 manualscan( ) manualscan- ; count --- 10225 (1 row) manualscan= select count(*) From

[GENERAL] Why does this SQL work?

2015-05-11 Thread Anil Menon
Hi, I have the following setup : manualscan= set search_path=ver736,public; SET manualscan= \d courier; Table ver736.courier Column | Type |Modifiers

Re: [GENERAL] RPM building tools and info missing?

2015-05-11 Thread Peter Eisentraut
On 5/9/15 10:47 AM, Bill Moran wrote: https://wiki.postgresql.org/wiki/RPM_Packaging The link to the specfiles and other data at http://svn.pgrpms.org/repo/ gives a 404. It's been move to git. I have updated the wiki page with the new URL. -- Sent via pgsql-general mailing list

Re: [GENERAL] Comparing txid and xmin (under BDR)

2015-05-11 Thread Craig Ringer
On 11 May 2015 at 21:10, Peter Mogensen a...@one.com wrote: Hi, I would really like to be able to externally to Postgres at some point in time later, be able to compare the txid of 2 queries. Namely: The INSERT transaction for a certain row in a table, and The SELECT transaction reading

Re: [GENERAL] Comparing txid and xmin (under BDR)

2015-05-11 Thread Peter Mogensen
On 2015-05-12 06:06, Craig Ringer wrote: On 11 May 2015 at 21:10, Peter Mogensen a...@one.com wrote: So ... I can easily get the current txid of the SELECT transaction by calling txid_current(). Note that by doing so, you force txid allocation for a read-only query that might otherwise not

Re: [GENERAL] Restarting DB after moving to another drive

2015-05-11 Thread Marc Mamin
Hi, have you checked that the links in $PGDATA\pg_tblspc on the new drive are valid ? They possibly still point to the old drive. I guess you have to correct them per hand before starting the moved DB. regards, Marc Mamin Von: