Libreoffice Base query with array

I want to make a query in libreoffice base where I want to get all elemts where the id is equal to an array of ids.

So i want to get the elements with id 1,2 and 3.

I thought that I can say in the query the Criterion is “= (1, 2, 3)” but this is not working.

How to get this working?

Actually, what you’re saying, §where id is equal to an array of ids§=the ID is an array and compared as such, which for first isn’t possible, and for second is mostly useless comparison.

Hi @tekkkz

You were close… you just have to use the IN operator, e.g.:

SELECT "CustomerID", "FirstName", "LastName" FROM "Customers" WHERE "CustomerID" IN (0, 1, 5)

Regards

@PYS - Thank you; I guess I’m not thinking today.