Received: from m72.tm.ee (adsl895.estpak.ee [213.168.23.133]) by mail.postgresql.org (8.11.3/8.11.1) with ESMTP id f2JKF1N74202 for ; Mon, 19 Mar 2001 15:15:02 -0500 (EST) (envelope-from hannu@tm.ee) Received: from tm.ee (localhost.localdomain [127.0.0.1]) by m72.tm.ee (Postfix) with ESMTP id 46E5A31B49; Mon, 19 Mar 2001 22:12:46 +0200 (CAT) Message-ID: <3AB6683E.5D0C3FEE@tm.ee> Date: Mon, 19 Mar 2001 22:12:46 +0200 From: Hannu Krosing X-Mailer: Mozilla 4.75 [en] (X11; U; Linux 2.4.2-7mdk i686) X-Accept-Language: et, en MIME-Version: 1.0 To: Yiming Huang Cc: pgsql-docs@postgresql.org Subject: Re: delete - is there any way to recover rows deleted from a table. References: <79BC7644A8501E4BB560D395FAECD30D0743B5@nic-nts1.nic.parallel.ltd.uk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Archive-Number: 200103/95 X-Sequence-Number: 529 Yiming Huang wrote: > > Hi, > > I was told that a delete command does not delete data from a table > physically. Is it correct? If it is true, could anyone to tell me whether > there is a way to recover to data deleted from a table? In the "original" postgres (not postgreSQL) you could just tell the backent the time interval you were interested in retrieveing. Currently It is not so easy, But the data is physically in the tables until you do a VACUUM; If you are desparate, I can send you some python code to get all data (both deleted and not) from the table. It gives you raw tuples - you have to write code to extract fields from tuples yourself. --------------- Hannu