postgrelize / CreateMaterializedViewOptions
Type Alias: CreateMaterializedViewOptions ​
CreateMaterializedViewOptions =
Readonly<{columns?: readonlystring[];ifNotExists?:boolean;using?:string;withData?:boolean; }>
Defined in: src/ddl/view-ddl.ts:48
postgrelize extensionOptions of createMaterializedView. PostgreSQL extension.
Example ​
ts
const options: CreateMaterializedViewOptions = { ifNotExists: true, withData: false };
await queryInterface.createMaterializedView('post_stats', 'SELECT count(*) AS n FROM "Posts"', options);