[SQL] Using Array in Function - Mailing list pgsql-sql

From Günce Kaya
Subject [SQL] Using Array in Function
Date
Msg-id CAAV2-mX-qXmcWaBjQYC-h3kFrqE4LObbh6WDefyeMy+PZAqwVw@mail.gmail.com
Whole thread Raw
Responses Re: [SQL] Using Array in Function  ("David G. Johnston" <david.g.johnston@gmail.com>)
List pgsql-sql
Hello,

I came across something strange about function. I have a function that has an input parameter is an array like integer[] and return json value. This input parameter is used in where clause. 

When I call function I'm using input parameter like '{int1,int2,int3}' then return only result for first one int1. If I only execute sql script that is in function with same parameter in where clause, sql script return 3 rows that we need. 

It seems so weird. Both of results should be same for function and sql script of function. 

What do you think about that? If you need I can share base of function structure. 

Regards, 
Gunce Kaya

pgsql-sql by date:

Previous
From: Rene Romero Benavides
Date:
Subject: Re: [SQL] Get relation name form relids in postgresql
Next
From: "David G. Johnston"
Date:
Subject: Re: [SQL] Using Array in Function