Genie Discord forum

Author Avatarrawjeev
12/15/2023, 8:36:46 AM

SELECT DISTINCT e.* FROM employeeprograms ep JOIN employees e ON ep.reports_to = e.id WHERE ep.employee_id = 8 AND ep.program_id = 1;

Author AvatarPere
12/15/2023, 5:26:44 PM

I think queries like that are beyond what Searchlight can do now. You'd have to directly use the query itself

Author Avatarrawjeev
12/18/2023, 1:35:46 PM

Can you tell me how do I directly execute a query using Searchlight?

I am in a bit of struggle with finding documentation or examples to learn what functions to call and how to use? Would be great if I could find a pointer towards where to look.

Author Avatarrawjeev
12/19/2023, 9:22:22 AM

I just figured out that I could use DBInterface to directly connect and execute some queries like the one I mentioned. Wondering if there are any implications to using SearchLight ORM along with DBInterface where I need some complex queries?

Are there any other mature ORM solutions that I can use with Genie framework that support different relationships and complex queries when required.

I came across FunSQL.jl and want to be trying that out a bit.

When I need to use different db libraries in the same app, can I use some connection pool from which I can share connections between different DB libraries?