CREATE TABLE "Test_schema"."Test_emp" (
"id" BIGINT,
"fname" VARCHAR(25),
"salary" BIGINT
)
GO
COMMENT ON TABLE "Test_schema"."Test_emp" IS 'Comment on table'
GO
CREATE VIEW "Test_schema"."test_emp_view"
AS
SELECT "id","fname" FROM "Test_schema"."Test_emp"
GO
COMMENT ON VIEW "Test_schema"."test_emp_view" IS 'Comment on view'
|
339 KB
![]() |
2 KB
The comments tab in the ER Modeler is not suppose to script view object comments. This tab is used by users to store there own comments on the view object. The comments tab for the table objects does script the comments on the table object. This was designed this way as per user request.
Noting this, that means there is an issue with Big Query & Hive as they are not suppose to be scripting the view comments here the ERM.
ER Modeler is designed to use view source when the view statement starts with "CREATE". So when we extract our view information, if the view source in the database does not start with CREATE we would construct the view source with the database information plus appending "CREATE" <variables> " AS " <database statement>.
It looks as if the extraction for big query and hive don't reconstruct the view source this way. EView class then checks the statement and because it doesn't start with CREATE it rebuilds the view using the scriptview.ScriptCREATE method. This method will script comments and though it looks as if its working correctly, it breaks the way users use ERM.
I will split this issue into 2 new issues, one for big query and one for hive.
Issue #14179 |
Closed |
Fixed |
Resolved |
Completion |
No due date |
No fixed build |
No time estimate |
2 issue links |
relates to #14197
Issue #14197Hive -> View comment script should not displayed comments code in ER-Modeler->view properties->SQL preview tab. |
relates to #14196
Issue #14196BIG QUERY -> View comment script should not displayed comments code in ER-Modeler->view properties->SQL preview tab. |
The comments tab in the ER Modeler is not suppose to script view object comments. This tab is used by users to store there own comments on the view object. The comments tab for the table objects does script the comments on the table object. This was designed this way as per user request.
Noting this, that means there is an issue with Big Query & Hive as they are not suppose to be scripting the view comments here the ERM.
ER Modeler is designed to use view source when the view statement starts with "CREATE". So when we extract our view information, if the view source in the database does not start with CREATE we would construct the view source with the database information plus appending "CREATE" <variables> " AS " <database statement>.
It looks as if the extraction for big query and hive don't reconstruct the view source this way. EView class then checks the statement and because it doesn't start with CREATE it rebuilds the view using the scriptview.ScriptCREATE method. This method will script comments and though it looks as if its working correctly, it breaks the way users use ERM.
I will split this issue into 2 new issues, one for big query and one for hive.