How to refresh materialized view in oracle

前端 未结 9 1462
小鲜肉
小鲜肉 2020-12-13 03:46

Iam trying to refresh the materialized view by using:

DBMS_MVIEW.REFRESH(\'v_materialized_foo_tbl\')

But it\'s throwing invalid sql stateme

相关标签:
9条回答
  • 2020-12-13 04:15

    Best option is to use the '?' argument for the method. This way DBMS_MVIEW will choose the best way to refresh, so it'll do the fastest refresh it can for you. , and won't fail if you try something like method=>'f' when you actually need a complete refresh. :-)

    from the SQL*Plus prompt:

    EXEC DBMS_MVIEW.REFRESH('my_schema.my_mview', method => '?');
    
    0 讨论(0)
  • 2020-12-13 04:20

    EXECUTE dbms_mview.refresh('view name','cf');

    0 讨论(0)
  • 2020-12-13 04:26

    Run this script to refresh data in materialized view:

    BEGIN
    DBMS_SNAPSHOT.REFRESH('Name here');
    END;
    
    0 讨论(0)
提交回复
热议问题