Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Engineers example broken under sqlite #229

Open
emiruz opened this issue Dec 17, 2022 · 1 comment
Open

Engineers example broken under sqlite #229

emiruz opened this issue Dec 17, 2022 · 1 comment

Comments

@emiruz
Copy link

emiruz commented Dec 17, 2022

Code:

%%logica Engineers
@Engine("sqlite");
Employee(name: "Alice", role: "Product Manager");
Employee(name: "Bob", role: "Engineer");
Employee(name: "Caroline", role: "Engineer");
Employee(name: "David", role: "Data Scientist");
Employee(name: "Eve", role: "Data Scientist");
Engineers(..r) :- Employee(..r), r.role == "Engineer";

Error:

OperationalError: no such column: Employee

I know that at this stage meaningful error messages may be a tall order but if it could perhaps print out the SQL statement it should be fairly easy to see what went wrong.

Also, sincerely thank you for this project: it is inspired.

@EvgSkv
Copy link
Owner

EvgSkv commented Dec 19, 2022

Hi @emiruz thank your for the report and supportive feedback.

I have added a warning about incompatibility of the syntax with SQLite.

I'll also fix the executor to show the query in case of an error like this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants