当前位置:网站首页>Mining pit record of modified field information in Dameng database
Mining pit record of modified field information in Dameng database
2022-06-26 00:42:00 【White as dust】
List of articles
1. summary
- Purpose : Modify all tables in the tablespace xxx Length of field .
- Realization : adopt SQL Make changes .
- problem : The navigation bar — Pattern — Table space — surface — Right click to view the table information , The field length has not been modified to .
- Tools :DM Management tools ( Dameng's own database management tool ).
2. The process
2.1 Problems arise
-- adopt SQL Find out xx A table whose field length meets the requirements , Concatenate the modified field length SQL
SELECT 'ALTER TABLE ' || t.table_name || ' MODIFY xxx VARCHAR(1);' AS str
FROM user_tab_columns t
WHERE t.column_name='xxx' AND t.data_length > 1;
-- Perform the spliced SQL, View table properties , The field length has not changed .
2.2 Refresh 、 Transaction commit attempt
Refresh table 、 Table space 、 Pattern 、 The connection has no effect . Looks like a big move , Restart the tool ; Close tooltip transaction not committed , That's the reason . perform COMMIT, Not yet. ( Later, we found that this transaction is a query statement (╯︵╰)).
2.3 Check SQL
SQL I didn't write it right , Fall into self doubt ( I'm using Oracle Of SQL sentence ). We can only see what the official documents of Damon say .
-- In document SQL Example :
ALTER TABLE PRODUCTION.PRODUCT_REVIEW MODIFY NAME VARCHAR(8) ;
sql No problem .
2.4 Verify that the table information of the navigation bar is not updated
- Through the initial query SQL, It is found that there is no data whose field length does not meet the requirements .
- adopt idea Of database Connect to database , It is found that the field length has been modified to .
3. summary
Daydream “DM Management tools ” A pit .
Directly modify the field length in the table attribute to ; use SQL modify , The navigation bar cannot be modified , But in fact, the modification was successful .
SQL How to update after modification , There is no way to refresh .
4. Problem solving
SQL There is no schema to get the table name in ( Schema name .table_name) Why , Only when the schema name is written will the field information in the navigation bar table attribute be updated ( Although the schema name in the document is optional , It's ok if you don't write ).
边栏推荐
- 渲云携手英特尔,共创云渲染“芯”时代
- 渗透工具-Burpsuite
- [TSP problem] solving traveling salesman problem based on Hopfield neural network with matlab code
- Drag the mouse to rotate the display around an object
- ORA-01153 :激活了不兼容的介质恢复
- 使用coe_load_sql_profile.sql固定执行计划
- Understanding of prototypes and prototype chains
- After being trapped by the sequelae of the new crown for 15 months, Stanford Xueba was forced to miss the graduation ceremony. Now he still needs to stay in bed for 16 hours every day: I should have e
- Wireshark's analysis of IMAP packet capturing
- Redux workflow + complete code of small examples
猜你喜欢

深圳台电:联合国的“沟通”之道

The development context of Ba Kong Yuan universe industry

What are the red lines of open source that should not be trodden on?

mtb13_ Perform extract_ blend_ Super{candidate (primaryalternate) \u unique (nullable filtering \foreign\index\granulati

Research and development practice of Kwai real-time data warehouse support system

Thrift getting started

把控元宇宙产业的发展脉络

When installing PSU /usr/bin/ld:warning: -z lazload ignore

Atlas200dk刷机

flink报错:No ExecutorFactory found to execute the application
随机推荐
渗透工具-Burpsuite
tensorrt pb转uff问题
Frequently asked questions about redis
《SQL优化核心思想》
Analysis and comparison of common test methods for PCBA in SMT chip processing industry
redux工作流程讲解+小例子
【ROS进阶篇】第一讲 常用API介绍
Daily question brushing record (IV)
Redux workflow explanation + small examples
Redux workflow + complete code of small examples
Performance leads the cloud native database market! Intel and Tencent jointly build cloud technology ecology
logstash丢弃没有精准匹配到文件名的日志数据
事物/现象/事情/东西/情况/表象
Correct writing methods of case, number and punctuation in Chinese and English papers
每日刷题记录 (四)
ffmpeg 版本切换
Tensorrt PB to UF problem
Redisson 3.17.4 发布
Machine vision: illuminating "intelligence" and creating a new "vision" world
Flink reports error: a JNI error has occurred, please check your installation and try again