On 6 Dec 2010, at 10:00pm, Oliver Peters wrote:

> [...]
> 
>> The wording is not completely correct indeed.
>> In general, views, triggers, and foreign key constraints can only
>> use objects within the same schema (=database).
>> 
>> That makes sense, because SQLite (and you) cannot guarantee the
>> other database file is attached when the view is used, the trigger
>> fires, or the reference is referred.
> 
> I think I've to go on asking because of a lack of basic knowledge but:
> 
> what is the problem to give the programmer/user the chance to decide on
> his own if he wants to use such a feature with all its included risks?

If you allow this, there's no way to do an integrity check on the resulting 
database files because users might rename or move the files that act as the 
second database.  Also, you have to invent another error condition for every 
command that might change the database, so it can report that the command 
itself is fine but the required database is not attached.

If you want this done, you can do it in your own code.  Or you can rethink the 
mismatch between what you mean by 'database' and what SQLite means by 
'database'.

Simon.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to