views:

30

answers:

1

Does MySQL have an equalavent to SQL Servers "indexed view" functionality?

http://stackoverflow.com/questions/439056/is-a-view-faster-than-a-simple-query

What I'm specifically looking for is a way for MySQL to create a "view" that will return results faster than simply performing the underline view's query/sql.

+1  A: 

An Indexed View is SQL Server terminology for a materialized view, which MySQL does not support.

You can either:

  • re-create a temporary table, populated with the desired columns, at a given interval
  • use an actual table, populated and indexed though again - there'd have to be a process to keep the data and indexes current
OMG Ponies
While considered a silver bullet, materialized views are notoriously constrained on any vendor. You can't use non-deterministic functions IE: SYSDATE or GETDATE, among other things.
OMG Ponies