-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Jeffrey Lichtman wrote:
> >> The PROPERTIES keyword and optimizer hints have been removed >> from Cloudscape before the code was contributed to Derby. >> I'm not sure where you've found the PROPERTIES keyword, but >> as far as I can tell it is no longer part of the manual. >> >> The reason it was removed is because the syntax is non-standard SQL. > > > Removing optimizer hints (and other hints) from the language because > they are non-standard is pretty ridiculous, in my opinion. Hints are > almost inevitably non-standard. The SQL standard doesn't even recognize > the concept of optimization, much less optimizer hints. > > Given that optimizer hints are useful (even necessary), how could one > support them in a "standard" way? I suppose they could be hidden in > comments, although building the support for this isn't simple Another potential way to support hints is to do it in configuration, outside of the application. Basically something that mapped from the query string to a set of hints. This would then allow hints to be applied to an existing application without any code changes, even to a compiled application. To me, this seems a far more flexible approach than requiring re-writes of the application. An XML form might be the easiest, something like <query> select a, b from s, t where c = d <hints> <table> s <index> sx </index> </table> <table> t <index> tx </index> </table> </hints> </query> Though, relying on XML for Derby will increase its footprint. Maybe there is a way to do something similar in the standard java properties format, or a derby format just for this issue. Dan. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFBcUBiIv0S4qsbfuQRAjYvAKDWrL9eUJZQnoaQN76rmlMrYGyLSgCdFHfZ 1rCMpvqMsCP6OIddf948xgA= =98JC -----END PGP SIGNATURE-----
