Hi Shankar,
If you want to create a local materialized view from a distributed table on the master node, then you can use a table instead:
CREATE TABLE testmview AS select * from github_events where event_id=
2489368089;
In this case to refresh the view you could to do something like this:
BEGIN;
CREATE TABLE prepare_view AS select * from github_events where event_id=
2489368089;
DROP TABLE IF EXISTS testmview;
ALTER TABLE prepare_view RENAME TO testmview;
COMMIT;
There is no notion of a "distributed materialized view" right now. Technically, it is possible to create a distributed table in which the shards are materialized views on shards, but you'd have to configure the shard metadata manually.
Hope this helps,
Marco