1.在hive中创建索引所在表 create table if not exists h_odse.hxy(id int,name string,hobby array<string>,add map<string,string>)partitioned by (age int,sex string)row format delimitedfields terminated by ','collection items terminated by '-'map keys termi…
因为表kol_xx_fin050_temp 为临时表,而且有其他session正在使用. 处理步骤: 1.先从 dba_objects / user_objects中查询到该表的object_id: select object_id from dba_objects where object_name=upper('kol_xx_fin050_temp'); 2.根据查到的object_id知道使用该表的session: select * from v$lock where id1=&objec…
最近要更新Cocon90.Db库,令其ORM创建表时实现索引的添加.因此总结下列常用Sql,供大家学习与参考. 一.SqlServer中创建索引可以这样: ) Create Table Test ( RowId ) NOT NULL, Name ) NOT NULL , Type int NULL, PRIMARY KEY (RowId,Name), INDEX idxType(Type), INDEX idxName(Name) ); 二.MySql中需要这样: CREATE TABLE IF…