PMACS / scenic_oracle_enhanced_adapter

OracleEnhanced adapter for Scenic gem.
MIT License
5 stars 2 forks source link

Create a refresh_schedule Option For Materialized Views #20

Open RaymondFallon opened 3 years ago

RaymondFallon commented 3 years ago

When using pmacs-rails_sql_views, we were able to pass a refresh_schedule option to the create_materialized_view method. This was a convenient way to tell your MVs, at creation time, when to refresh themselves. This is no long available with scenic, but it would be a nice option to build in.

Considerations

riyengar8 commented 1 year ago

To add to this issue, I think the refresh_materialized_view method in this adapter is wrong.

UserCourse.refresh

I think the correct way to refresh a MV in Oracle is something like so:

BEGIN
  DBMS_SNAPSHOT.REFRESH('MVIEW_NAME');
END;

Maybe this should be a separate issue as it is not directly related to the fact that there's no ability to create a refresh schedule on create.

riyengar8 commented 1 year ago

I made a new issue for my comment above:

https://github.com/PMACS/scenic_oracle_enhanced_adapter/issues/22