-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #118 from ragi256/modify_redshift_adapter_to_suppo…
…rt_late_binding_view Support late binding view
- Loading branch information
Showing
13 changed files
with
138 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
class ViewMetaDatum < ApplicationRecord | ||
belongs_to :table_memo | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
.box.data-box | ||
.box-header | ||
%h3.box-title Data | ||
.box-body | ||
- if @raw_dataset | ||
%table.table.table-hover.table-bordered.table-striped.text-sm{ role: "grid" } | ||
%tr | ||
- @raw_dataset_columns.each do |column| | ||
%th #{column.name} (#{column.sql_type}) | ||
- if @table_memo.masked? | ||
%tr | ||
%td.text-center{ colspan: @raw_dataset_columns.size } | ||
= t("masked_table") | ||
- else | ||
- database_name = @table_memo.database_memo.name | ||
- table_name = @table_memo.name | ||
- @raw_dataset_rows.each do |row| | ||
%tr | ||
- Array.wrap(row).each_with_index do |value, i| | ||
- column = @raw_dataset_columns[i] | ||
%td | ||
- if MaskedDatum.masked_column?(database_name, table_name, column.name) | ||
= t("masked_text") | ||
- else | ||
= value | ||
.pull-right.block | ||
#{@raw_dataset_rows.try(:size).to_i} / #{@raw_dataset.count || '?' } records | ||
- else | ||
= t("no_preview_dataset") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
.box.data-box | ||
.box-header | ||
%h3.box-title View Query | ||
.box-body | ||
%pre | ||
%code= @view_meta_data.query | ||
|
||
.box.data-box | ||
.box-header | ||
%h3.box-title View Query Plan | ||
.box-body | ||
%pre | ||
%code= @view_meta_data.explain | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
create_table "view_meta_data", force: :cascade do |t| | ||
t.integer "table_memo_id", null: false | ||
t.text "query", null: false | ||
t.text "explain", null: false | ||
t.datetime "created_at", null: false | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters