Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1XC3J3-0003cV-A5 for pgsql-php@arkaria.postgresql.org; Tue, 29 Jul 2014 09:02:49 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1XC3J2-0002N8-3c for pgsql-php@arkaria.postgresql.org; Tue, 29 Jul 2014 09:02:48 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1XC3J0-0002Lz-1a for pgsql-php@postgresql.org; Tue, 29 Jul 2014 09:02:46 +0000 Received: from mail-wi0-x229.google.com ([2a00:1450:400c:c05::229]) by magus.postgresql.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.80) (envelope-from ) id 1XC3Iv-0007hr-Ro for pgsql-php@postgresql.org; Tue, 29 Jul 2014 09:02:44 +0000 Received: by mail-wi0-f169.google.com with SMTP id n3so5443787wiv.4 for ; Tue, 29 Jul 2014 02:02:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=F7VQ/g/pAHrp1ACs9hLKL8gJnb+4gUGnXiY0ln9dg0U=; b=OiNveU92nwz7TJI3YJEvdXHH0WNZr/b3RjNq9IzCWjQwgR7geKMZ5kbLw+nACZFdiP i/fFSV04Q8IGe7Jhb2tO/b1WYyYm3jj61uwhiTbcB+HzJgYjZ4Qf8I/nsnhlvJiYoCKa mN5WJuPAe0TmH71yhvkLxW+adTictbaFIiRVEJeGKQBejCWItesTAQd5Q9nI/9Wfs2Ag MDcsIGwFS2ZCRejBpcjERAEfAtDscT0B2U5BXeBkRJrQed6OpsAVDm71ZhABO0ebO97p E9FawTHLC7c5tun2n5Z1QxwiaaBcHU0nMLYII7ii89SIClsm8sGiWjHqjj9kZD/kOV7X oluA== X-Received: by 10.194.175.41 with SMTP id bx9mr879400wjc.123.1406624557464; Tue, 29 Jul 2014 02:02:37 -0700 (PDT) Received: from [192.168.1.120] (178-18-170-101.customer.bnet.at. [178.18.170.101]) by mx.google.com with ESMTPSA id f16sm41139358wic.7.2014.07.29.02.02.36 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Jul 2014 02:02:36 -0700 (PDT) Message-ID: <53D76329.9080309@php.net> Date: Tue, 29 Jul 2014 11:02:33 +0200 From: Michael Wallner User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Jeff Silberberg , pgsql-php@postgresql.org Subject: Re: Looking for some assistance / guidance -- References: In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-php Precedence: bulk Sender: pgsql-php-owner@postgresql.org On 29/07/14 02:45, Jeff Silberberg wrote: > echo "User Keys " . gettype($userKey)."
\n"; confirms this is > a Array .. An I have tried casting $1::int[] in the prepare with no > luck.. > You have to format it as postgresql array string, so that it can be parsed as array by the server, e.g: '{1,2,3}'::int[] So, assuming they keys are integers: $userKey = "{".implode(",",array_map("intval", $userKey))."}::int[]"; -- Regards, Mike -- Sent via pgsql-php mailing list (pgsql-php@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-php