Redian新闻
>
how to list all tables in my account?
avatar
how to list all tables in my account?# Database - 数据库
ak
1
could i list all tables in my account? what's the command?
i am a new user.
thanks!
avatar
m*t
2

I believe this is database-dependent.

【在 ak 的大作中提到】
: could i list all tables in my account? what's the command?
: i am a new user.
: thanks!

avatar
g*o
3
Try this two
1). select OBJECT_NAME from USER_OBJECTS where OBJECT_TYPE='TABLE';
2). select OBJECT_NAME from ALL_OBJECTS where OBJECT_TYPE='TABLE' and OWNER =
'your_userid';

【在 ak 的大作中提到】
: could i list all tables in my account? what's the command?
: i am a new user.
: thanks!

avatar
F*a
4
The simplest is to use the ALL_TABLES:
select TABLE_NAME from ALL_TABLES where OWNER = 'XXX';

=

【在 g***o 的大作中提到】
: Try this two
: 1). select OBJECT_NAME from USER_OBJECTS where OBJECT_TYPE='TABLE';
: 2). select OBJECT_NAME from ALL_OBJECTS where OBJECT_TYPE='TABLE' and OWNER =
: 'your_userid';

avatar
a*c
5
Select tname from tab;

=

【在 g***o 的大作中提到】
: Try this two
: 1). select OBJECT_NAME from USER_OBJECTS where OBJECT_TYPE='TABLE';
: 2). select OBJECT_NAME from ALL_OBJECTS where OBJECT_TYPE='TABLE' and OWNER =
: 'your_userid';

avatar
m*t
6

if it's oracle,
select table_name from user_tables;
would be my favorite.

【在 F***a 的大作中提到】
: The simplest is to use the ALL_TABLES:
: select TABLE_NAME from ALL_TABLES where OWNER = 'XXX';
:
: =

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。