BTEQ 查询未返回所有列 [英] BTEQ query not returning all the columns

查看:30
本文介绍了BTEQ 查询未返回所有列的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在创建一个 unix 脚本来一次性获取表中每列的空计数(使用 BTEQ).我的查询是这样的:select count() - count(column_name1), count() - count(column_name2).... from table_name;查询返回 1 行和编号.空计数的列数.我在一张表中有 900 多列.但是查询在 BTEQ 中运行时不能只返回 818 列.是否有任何解决方案可以返回所有列并将计数存储在文件中.

I am creating a unix script to get null counts of each column in a table in one go(USING BTEQ). My query is like : select count() - count(column_name1), count() - count(column_name2).... from table_name; The query returns 1 row and the no. of columns with its null count. I have more than 900 columns in one table. But the query is not able to return only 818 columns when running in BTEQ. Is there any solution to return all the columns and store the count in a file.

推荐答案

使用以下SET命令在Bteq控制台查看列

use following SET commands for viewing columns in Bteq console

$ bteq

 Enter your logon or BTEQ command:
.logon $HOST/$USER
Password: $PASS

.Set Format off
.Set Recordmode off
.Set Echoreq on
.Set Separator '|'
.width 3000
.Set Titledashes on


SELECT * FROM <DB>.<TABLE>;

这篇关于BTEQ 查询未返回所有列的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆