# 一般資料庫

一般資料庫是一種表格，其中欄位名稱會儲存為一個資料行中的欄位值，而欄位值則儲存在下一個資料行內。一般資料庫通常用於各種物件的屬性。

看看以下範例 GenericTable。這是包含兩個物件 (球和箱子) 的一般資料庫。顯然地，一些屬性 (像色彩和重量) 是兩個物件都有的，而其他屬性 (像直徑、高度、長度及寬度) 則非兩個物件都有。

一般範例表格

| object | attribute | value |
| --- | --- | --- |
| ball | color | red |
| ball | diameter | 10 cm |
| ball | weight | 100 g |
| box | color | black |
| box | height | 16 cm |
| box | length | 20 cm |
| box | weight | 500 g |
| box | width | 10 cm |

一方面而言，如果指定每個屬性給其個別的資料行，這種資料儲存方式並不太適合，因為許多屬性和某個特定物件無關。

另一方面而言，將長度、色彩及重量混合在一起顯示，看起來很雜亂。

如果使用標準方式將此資料庫載入 QlikView，並在表格中顯示資料，則資料將如下所示：

![Example data table display, with three separate data lists titled 'object', 'attribute', and 'value'](https://help.qlik.com/zh-TW/qlikview/September2026/Subsystems/Client/Content/Resources/Images/ex_gen_generic2.png)

然而，如果將此表格以一般資料庫的方式載入，會將第二個和第三個資料行分割成不同的表格，分別屬於第二個資料行的每個獨特值：

![Example data table display, with seven separate data lists titled for each unique entry in the table](https://help.qlik.com/zh-TW/qlikview/September2026/Subsystems/Client/Content/Resources/Images/ex_gen_generic3.png)

此方式的語法非常簡單：

範例：

`Generic SELECT* from GenericTable;`

無論使用 LOAD 或 SELECT 陳述式來載入一般資料庫皆可。