Received: from localhost (unknown [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id 10B969FB7C8 for ; Thu, 30 Aug 2007 15:32:30 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-maia, port 10024) with ESMTP id 46916-03 for ; Thu, 30 Aug 2007 15:32:12 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from dfbsa63.conab.gov.br (dfbsa63.conab.gov.br [200.140.131.205]) by postgresql.org (Postfix) with ESMTP id 260349F9D92 for ; Thu, 30 Aug 2007 15:32:20 -0300 (ADT) Received: from [10.131.1.6] (RSSEDEM2.conab.gov.br [10.131.1.6]) by dfbsa63.conab.gov.br (Postfix) with ESMTP id 3F3D3940D9; Thu, 30 Aug 2007 15:32:05 -0300 (BRT) Message-ID: <46D70D18.5060501@conab.gov.br> Date: Thu, 30 Aug 2007 15:31:52 -0300 From: Roberto Spier User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) MIME-Version: 1.0 To: marchesini@unipg.it CC: pgsql-sql@postgresql.org Subject: Re: date problems References: <1188478863.4876.23.camel@ivangeo> In-Reply-To: <1188478863.4876.23.camel@ivangeo> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.158 tagged_above=0 required=5 tests=AWL=0.898, BAYES_20=-0.74 X-Spam-Level: X-Archive-Number: 200708/256 X-Sequence-Number: 29194 ivan marchesini escreveu: > Dear PG users, > I have an access db and I'm trying to pass all to postgres > I have used mdbtools to export the schema and all went quite well. > then I exported the single tables... to csv.. > > a lot of table have some timestamp fields containing data as DD/MM/YYYY, > and I'm no able to copy this table into postgres... because it needs > YYYY/MM/DD... > I used \copy... > > Which is the best solution for this problem... > > many thanks > > Ivan > > another approach: from within your access .mdb file, connect your new pg tables through ODBC. Then execute an INSERT INTO pg_table(...) SELECT ... FROM acc_table; spier