Want to generate below query using pypika for postgresql.
select name, employee_id
from employee
where phone_no && ARRAY['7377','3877','9277']::varchar[]
Is there any way we can achieve this?
Want to generate below query using pypika for postgresql.
select name, employee_id
from employee
where phone_no && ARRAY['7377','3877','9277']::varchar[]
Is there any way we can achieve this?
Copyright © 2021 Jogjafile Inc.
Yes, surely you can generate this query using pypika for postgresql.Try this;
To see if any member in the phone_no array matches any element in the given phone_numbers array, I used the like_any method in this query.
Hope it's helpful :)