GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing docs.voltactivedata.com — ALTER VIEW Using VoltDBALTER VIEWALTER VIEW — modifies the TTL settings of an existing stream view SynopsisALTER VIEW view-name ALTER USING TTL value [time-unit]
ON COLUMN column-name time-unit: SECONDS | MINUTES | HOURS | DAYS DescriptionThe ALTER VIEW statement lets you modify the USING TTL clause of a stream view. Note that the ALTER statement can only be used to modify a stream view (not a view on a regular database table) and that you can only change the USING TTL clause. What's more, although you must specify the entire USING TTL clause including the column specification, you can only change the time value, batch size or maximum frequency. You cannot change the TTL column or add or remove the USING TTL clause entirely. To add a USING TTL clause to a stream view without one, to remove an existing USING TTL clause, or to change the TTL column, you must first drop the view then recreate it (using the DROP VIEW and CREATE VIEW statements). ExamplesThe following example creates a stream view with a USING TTL clause, then uses ALTER VIEW to reduce the TTL value and change the batch size to 500. CREATE VIEW logins_per_day
(userid, session_day, total_count)
AS SELECT userid, TRUNCATE(DAY, start_time), count(*)
FROM user_session GROUP BY userid, TRUNCATE(DAY, start_time)
USING TTL 7 DAYS ON COLUMN session_day;
ALTER VIEW logins_per_day ALTER USING TTL 3 DAYS ON COLUMN session_day
BATCH_SIZE 500; |
| You are visitor 01402775 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |