On Tue, 23 Oct 2012 10:00:02 -0700, Tim Meagher <[email protected]> wrote:
> Hi Mary, > > Thanks for the clear and useful answers. Just to follow up, we have a > scenario where we have a custom schemas database that points to the > default Schema database. (neither of which contains any schemas). Would > it be fair to say that if the schemas database is accessed every time an > uncached schema is required for some purpose and if a schema cannot be > found in the custom schemas database, that it will try to look for a > schema in the default Schemas database? We are trying to correct some > performance issues. The "Schemas" database isn't default in any sense other than it is created by the standard install and it is chosen as the default for every new database. It isn't treated as special by any processing. So, if I am running a query against database X, then I will look for all schemas in database schemas-database(X). The schemas database of a database used for schemas is only referenced when running against that database. OK, that was less than clear: X = database S = schemas-database(X) S2 = schemas-database(S) The only time we look in S2 for schemas is if you are operating on data in S. So what database S2 is only makes a material difference for the processing of the type/whitespace/validation of the schemas themselves. Unless you are using schema annotations, this means that the only relevant schema is the schema for schemas, which is built in anyway so the identity of S2 is irrelevant. If you *are* using schema annotations, you probably want S=S2 just so you can manage all your schemas in one place and be tidy about it, but you could make it work putting your data schemas in S and your annotation schemas in S2 if you want. //Mary _______________________________________________ General mailing list [email protected] http://developer.marklogic.com/mailman/listinfo/general
