Forum OpenACS Development: Making db_map throw an error if query doesn't exist
Posted by Peter Marklund on 07/15/03 11:15 AM
Would it be reasonable to make db_map throw an error if you try to look up a query that doesn't exist? Actually it boils down to being the proc db_qd_internal_get_cache that wil throw the error. I've made the change and it seems to work fine.
It certainly helps development work if OpenACS tells you when you've misspelled a query or moved a query from one proc to another and forgot to update the proc name in the xql file. Silent failures is one of the very worst sins of programming IMHO.
2: Re: Making db_map throw an error if query doesn't exist (response to 1)
Posted by Jun Yamog on 07/15/03 02:31 PM
Yes definitely. Bit me a bit a long time ago. But I guess not much to rant about it. But Yes we need it to throw an error.