I now want to use 'like' function with JOOQ to select data including array of string data by not case sensitive and partitial-match.
Table schema is:
CREATE TABLE favorites (
id int,
items varchar(100)[]
);
Sample data is:
INSERT INTO favorites (id, items)
VALUES (1, '{orange, lemon, banana}');
INSERT INTO favorites (id, items)
VALUES (2, '{apple, grape}');
To get first data, SQL is like:
SELECT id, items FROM favorites WHERE 'orange' = ANY (items);
My Goal is to select data by case-sensitive and partitial-match like: For example, using likeIgnoreCase("OraNge") or like("%ang%") ?
To develop below code with LIKE function:
Connection connection = ...;
DSLContext context = DSL.using(connection, ...);
List<Table> table = context.select().from(TABLE).fetchInto(Table.class);
How can I use like function?
Thank you in Advance.