× Heads up!

Aqua Data Studio / nhilam

Follow
IDE for Relational Databases
×
anilkalshetti reported 2015-11-20T07:25:55Z  · tariqrahiman last modified 2017-05-22T17:38:06Z

Alter Table- Script generated in Preview SQL- TableName and ColumnName should be in backticks


Priority Low
Complexity Unknown
Component Hive
Version 19.0

Aqua Data Studio 17.0.0-rc-39
Build #: 47130
Built on: 2015-Nov-19 03:07:33 PM         

OS: Ubuntu 14.04
Linux (3.13.0-59-generic, amd64) / UTF-8 / en / IN / Oracle Corporation 1.8.0_40-b26
Memory: Max=704,643,072;  Total=578,813,952;  Free=226,655,184;  CPUs=8

Database: MapR 5.0 Hive 1.0.0
Driver: Hive 1.0.0 Download link
 

Issue: Alter Table- Script generated in Preview SQL- TableName and ColumnName should be in backticks

Steps:

1. Create table using below script.

CREATE TABLE `client`  ( 
`col1` string, 
`col2` string, 
`col3` string, 
`col4` string)
ROW FORMAT DELIMITED
STORED AS TEXTFILE
 
2. Right click on Table, select 'Alter Table',  
-a] In General Tab
    - add new column
    - add comment to existing column
    - rename column name
 b] Comments Tab
   - add comment  - this is comment for table
 c] Storage Tab
    - Change Stored AS  from TEXTFILE to SEQUENCEFILE
    - Add Clustered By field - col1
    - Add number of buckets - 13
    - Fields Terminated By -  ,
 
3. Observe the Alter Script generated in  Preview SQL tab
 - For General and Comments Tab- Alter Table script - Table Name is in backticks   (` `)
 - For Storage Tab- Alter Table script - backticks are not present for table name
 
ALTER TABLE `client`
ADD COLUMNS (
`col5` string
)
GO
ALTER TABLE `client`
CHANGE `col3` `col7` string COMMENT ''
GO
ALTER TABLE `client`
CHANGE `col4` `col4` string COMMENT 'comment-col4'
GO
ALTER TABLE `client`
SET TBLPROPERTIES ('comment'='table comment-ADS17-rc-39')
GO
ALTER TABLE client
CLUSTERED BY (col1
INTO 13 BUCKETS
GO
ALTER TABLE client SET FILEFORMAT SEQUENCEFILE
GO
ALTER TABLE client SET SERDEPROPERTIES ('field.delim'=',')
GO
 
Expected: backticks should be provided for TableName and ColumnName -  Refer last 3 Alter Table Statements- [related to Storage Tab]
 
@Dev:
1. Script generated should be identical, In all scripts TableName and ColumnName should be in backticks.
2. When TableName is any reserved keyword or ColumnName contains Unicode characters,
 Backtick quotation will enables the use of reserved keywords for table and column identifiers.
5 attachments

Issue #13877

Closed
Fixed
Resolved 2017-04-12T23:02:57Z
 
 
Completion
No due date
Fixed Build ADS 19.0.0-dev-21
No time estimate

About AquaClusters Privacy Policy Support Version - 19.0.2-4 AquaFold, Inc Copyright © 2007-2017