If you want to return calculated data values to your application, you can improve performance by running computations in your database rather than when the data is requested. 如果你想将计算出的数据值返回给应用程序,你可以通过在数据库中运行计算来提高性能,而不是在请求数据时运行。The application may require either precise calculations or approximate results. By using the Computed and the Approximation schema patterns, you can pre-compute and store the resulting values ahead of time (for example on insert or with a periodic task) so they are readily available when you request the data.应用程序可能需要精确计算或近似结果。通过使用Computed和Approximation模式,您可以提前预计算和存储结果值(例如在插入或周期性任务时),以便在您请求数据时随时可用。
Use Cases用例
Get Started开始使用
To learn how to apply design patterns for computed values, see these pages:要了解如何将设计模式应用于计算值,请参阅以下页面: