

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 列出指定資料庫中的資料表，並依名稱搜尋資料表
<a name="querying-glue-catalog-listing-tables"></a>

若要列出資料表的中繼資料，您可以透過資料表模式或資料表名稱查詢。

**Example – 依結構描述列出資料表**  
下列查詢會列出使用 `rdspostgresql` 資料表模式的資料表。  

```
SELECT table_schema,
       table_name,
       table_type
FROM   information_schema.tables
WHERE  table_schema = 'rdspostgresql'
```
下列資料表會顯示範例結果。  


****  

|  | table\$1schema | table\$1name | table\$1type | 
| --- | --- | --- | --- | 
| 1 | rdspostgresql | rdspostgresqldb1\$1public\$1account | BASE TABLE | 

**Example – 依名稱搜尋資料表**  
下列查詢包含 `athena1` 資料表的中繼資料資訊。  

```
SELECT table_schema,
       table_name,
       table_type
FROM   information_schema.tables
WHERE  table_name = 'athena1'
```
下列資料表會顯示範例結果。  


****  

|  | table\$1schema | table\$1name | table\$1type | 
| --- | --- | --- | --- | 
| 1 | 預設 | athena1 | BASE TABLE | 