Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id C32A3B5DBF8; Fri, 27 May 2011 14:09:56 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 68110-07; Fri, 27 May 2011 17:09:49 +0000 (UTC) X-Greylist: delayed 00:57:04.04247 by SQLgrey-1.7.6 X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from oldperseverance.encs.concordia.ca (oldperseverance.encs.concordia.ca [132.205.96.94]) by mail.postgresql.org (Postfix) with ESMTP id 9D13DB5DBBF; Fri, 27 May 2011 14:09:49 -0300 (ADT) Received: from cacao.encs.concordia.ca (emilu@cacao.encs.concordia.ca [132.205.47.225]) by oldperseverance.encs.concordia.ca (envelope-from emilu@encs.concordia.ca) (8.13.7/8.13.7) with ESMTP id p4RGF00t022198; Fri, 27 May 2011 12:15:00 -0400 Message-ID: <4DDFCE04.2050402@encs.concordia.ca> Date: Fri, 27 May 2011 12:15:00 -0400 From: Emi Lu Reply-To: emilu@encs.concordia.ca User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.16) Gecko/20101125 Lightning/1.0b1 Thunderbird/3.0.11 MIME-Version: 1.0 CC: Jasen Betts , pgsql-general@postgresql.org, PostgreSQL SQL List Subject: Re: 500KB PDF files for postgresql8.3, which is the most efficient way? References: <482E80323A35A54498B8B70FF2B87980049413B5EB@azsmsx504.amr.corp.intel.com> <482E80323A35A54498B8B70FF2B87980049413B673@azsmsx504.amr.corp.intel.com> <4DDEC3B1.2050008@boscorama.com> <4DDFCD7A.8030902@encs.concordia.ca> In-Reply-To: <4DDFCD7A.8030902@encs.concordia.ca> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.58 on oldperseverance.encs.concordia.ca at 2011/05/27 12:15:00 EDT X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-0.889 tagged_above=-5 required=5 tests=BAYES_00=-1.9, MISSING_HEADERS=1.021, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201105/869 X-Sequence-Number: 176301 Hello, I'd like to have more comments about the following case: > . 500KB per PDF file; 30 files per year > . PSQL8.3 . struts2.2.3 + mybatis for sql operation . tomcat6 Added more info Solution: ==================== (1) Save pdfs to file system, only point file name in psql8.3 (2) Save oids of pdfs into table (3) Save pdf files as bytea column in psql8.3 Pros and cons for (1), (2), (3), which is the most efficient way? Thanks a lot! Emi