On Fri, 19 May 2017 13:06:23 -0600 "Keith Medcalf" <kmedc...@dessus.com> wrote:
> You asked for the extra index to be created in the table > specification. It is not the job of the database engine to correct > your errors (it is not even possible to know if it is an error). He didn't ask. It's not an error. And it is within the purview of the DBMS to make any implementation decision it wishes to effect the described outcome. Other than that, we agree! Nothing about any SQL statement implies anything about the implementation. Thus, as you know, a unique constraint is not an instruction to build an index, much less a requirement to build a redundant one. It's a rule. Carry it out as ye may. Redundant constraints are not errors. They're not wrong in any sense. They're not minimal, that's all. The logical redundancy can be ascertained by the system, and there the redundancy can be excised. Nothing forces the DBMS to check twice something that need be checked only once. I appreciate that there are other constraints on the system, such as backwards compatibility and feasibilty. That's fine. But let's not gussy up pragmatic choices or problematic history as logically mandated. If we do, we're apt to miss opportunities to make improvements, and teach users the wrong lessons about what to do. --jkl _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users