oatpp-sqlite icon indicating copy to clipboard operation
oatpp-sqlite copied to clipboard

query param use array: SELECT...in ( array)

Open kekxv opened this issue 2 years ago • 3 comments

How to do it:

SELECT * FROM users WHERE username in (:usernames);

:usernames is array

kekxv avatar Jun 22 '23 06:06 kekxv

Have you found the solution?

samjayhk avatar Jan 31 '25 09:01 samjayhk

Dear @lganzzzo

Thanks for your great work!

I'm encountering an issue with the IN() command in oatpp-SQLite. It seems that currently, there is no way to insert string parameters that are not supported by the scope (such as "12,14,15" for IN()), whether using the IN() command or simply using the OR command. However, if I hardcode the QUERY command with IN() or OR, it works as expected.

Is there a workaround or a recommended approach to handle this issue?

Thank.

samjayhk avatar Jan 31 '25 13:01 samjayhk

not yet

kekxv avatar Feb 03 '25 01:02 kekxv