SQLite Foreign key ignored

Thanks both for the reply.

I did try before in a Node-red prepared command:

PRAGMA foreign_keys = On;
delete from artist
where artistid = 1;

Result, does not delete nor error

delete from artist
where artistid = 1;
PRAGMA foreign_keys = On;

Result, does not delete nor error neither

So as soon as I put this statement in the prepare query, it does not delete but it does not give me an error in the console either. I am missing something or it might be a bug in the SQLite Node red.