Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1UHcwu-0007Ny-24 for pgsql-bugs@arkaria.postgresql.org; Mon, 18 Mar 2013 16:30:12 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1UHcwt-0005se-8t for pgsql-bugs@arkaria.postgresql.org; Mon, 18 Mar 2013 16:30:11 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1UHVLp-00031I-Na for pgsql-bugs@postgresql.org; Mon, 18 Mar 2013 08:23:25 +0000 Received: from mahout.postgresql.org ([2001:4800:7903:4::123]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1UHVLl-0001Mw-11 for pgsql-bugs@postgresql.org; Mon, 18 Mar 2013 08:23:25 +0000 Received: from [204.145.124.246] (helo=wrigleys.postgresql.org) by mahout.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1UHVLh-00046h-5s for pgsql-bugs@postgresql.org; Mon, 18 Mar 2013 08:23:20 +0000 Received: from www-data by wrigleys.postgresql.org with local (Exim 4.72) (envelope-from ) id 1UHVLg-0003bi-Uj for pgsql-bugs@postgresql.org; Mon, 18 Mar 2013 08:23:16 +0000 Date: Mon, 18 Mar 2013 08:23:16 +0000 Message-Id: Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Subject: BUG #7967: Wrong week number in extract function To: pgsql-bugs@postgresql.org From: noose@noose.pl X-Pg-Spam-Score: -4.4 (----) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org The following bug has been logged on the website: Bug reference: 7967 Logged by: Pawel Kobylak Email address: noose@noose.pl PostgreSQL version: 9.1.3 Operating system: Debian Description:=20=20=20=20=20=20=20=20 Hi, I'm running that query and result is ... unexpected for me... Query: select '2012-12-31', EXTRACT(year from '2012-12-31'::date), EXTRACT(week from '2012-12-31'::date) Result: "2012-12-31";2012;1 Expected: "2012-12-31";2012;53 OR "2012-12-31";2013;1 This result is correct? Or that is little bug? :-) Regards, Pawel --=20 Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs