【Hive-SQL】Hive Select 选择语句排除一列或多列

  • 查看除了sample_date以外的所有字段信息
sql 复制代码
set hive.support.quoted.identifiers=none; 

select `(sample_date)?+.+` 
from `test`.`table` where sample_date='20230713';
  • 查看除了sample_date 和 msgtype以外的所有字段信息
sql 复制代码
set hive.support.quoted.identifiers=none; 

select `(sample_date|msgtype)?+.+` 
from `test`.`table` where sample_date='20230713';

上面的 set hive.support.quoted.identifiers=none; 可以替换操作:

'hive-site.xml' 中添加以下配置:
hive.support.quoted.identifiers=none

相关推荐
云和恩墨1 分钟前
AI驱动的Oracle SQL优化:从经验依赖到智能协同的三大价值
人工智能·sql·oracle·深度优先·dba
F***E2392 小时前
SQL中的REGEXP正则表达式使用指南
数据库·sql·正则表达式
对 酒 当 歌 人 生 几 何3 小时前
Mysql多表连接
数据库·sql·mysql
用户7227868123444 小时前
SQL中的CTE用法初步(Common Table Expression公共表表达式)
sql
却尘4 小时前
用 25 个概念彻底看懂SQL多维分析的底层逻辑
后端·sql·mysql
快乐非自愿5 小时前
SQL Server 2025 新功能概览
sql
伐尘5 小时前
【MySQL】MySQL 有效利用 profile 分析 SQL 语句的执行过程
android·sql·mysql
s***46986 小时前
SQL 中UPDATE 和 DELETE 语句的深入理解与应用
数据库·sql
allione6 小时前
数据库中容易混淆的关键字alter/update...
数据库·sql
Macbethad6 小时前
WPF工业设备诊断管理程序技术方案
大数据·hadoop·分布式