Looking Up Values From a Database

It's possible to store these kinds of values in a database. The benefit of this approach is that it's possible to change the settings for all of the users without having to distribute new copies of the workbook or application. It also offers the most flexibility regarding securing the values. The main drawbacks of this method are that it requires a database connection and it's slower than the other methods. If you don't want to assume a constant database connection, you could use one of the other approaches for short-term needs and occasionally connect to the database for updates.

Consider using a database to store literal values that have short half-lives. That is, literal values that are likely to change over the life of the application. The more difficult it is to distribute new versions of the application, the more attractive this option becomes. For example, if the application is distributed to hundreds or thousands of users across the organization, it may be cost-effective to have an application that knows how to update itself rather than redistribute new versions of the application or otherwise force users to always "check the intranet for the latest version."

NOTE Database coverage begins in Chapter 16.

0 0

Post a comment