I think I found a solution to it !  

If the cost of it is too much for normal operation we could have a "pragma
debug_foreign_key" (or debug everything) and turn it on, then run again the
failed statement and in this mode extra code that saves all info for a
detailed error message can be run without problem.  

?  
>  Mon Apr 04 2016 07:49:57 PM CEST from "Domingo Alvarez Duarte"
><sqlite-mail at dev.dadbiz.es>  Subject: Re: [sqlite] FOREIGN KEY constraint
>failed
>
>  Thank you for reply ! 
> 
> Good point, but for sure there is great minds here that can come with a
> solution to this problem ! 
> 
> Sqlite could use a table in memory (or a hash table) and add delete from it
> as it found violations/resolve then and at then end it has all the
>violations
> to show, it can be done lazy so if no violations occur no hash table is
>ever
> created. 
> 
> 
> The actual situation is better than nothing but it's still frustrating ! 
> 
> Cheers ! 
>  
>>Mon Apr 04 2016 07:39:19 PM CEST from "Clemens Ladisch"
>> <clemens at ladisch.de> Subject: Re: [sqlite] FOREIGN KEY constraint failed
>> 
>> Domingo Alvarez Duarte wrote:
>> 
>>  
>>>But even then could it have let's say a place for record the last foreign
>>> key
>>> violation ?
>>> 
>>> 

>>  This would not help if that last constraint is no longer violated at the
>> end of the transaction.
>> 
>> 
>> Regards,
>> Clemens
>> _______________________________________________
>> sqlite-users mailing list
>> sqlite-users at mailinglists.sqlite.org
>> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>> 
>> 
>> 
>> 
>> 
>> 

>  ?
> 
> _______________________________________________
> sqlite-users mailing list
> sqlite-users at mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
> 
>
>  



?

Reply via email to