檢查表格的結構

若要從資料庫檢查資料表的結構,請在將資料表的路徑指定為查詢引數時執行GET要求。

API格式

GET /connections/{BASE_CONNECTION_ID}/explore?objectType=table&object={TABLE_PATH}
參數說明
{BASE_CONNECTION_ID}資料庫連線的識別碼。
{TABLE_PATH}表格的路徑。

要求

curl -X GET \
    'https://platform.adobe.io/data/foundation/flowservice/connections/6990abad-977d-41b9-a85d-17ea8cf1c0e4/explore?objectType=table&object=test1.Mytable' \
    -H 'Authorization: Bearer {ACCESS_TOKEN}' \
    -H 'x-api-key: {API_KEY}' \
    -H 'x-gw-ims-org-id: {ORG_ID}' \
    -H 'x-sandbox-name: {SANDBOX_NAME}'

回應

成功的回應會傳回指定資料表的結構。 有關每個資料表資料行的詳細資料位於columns陣列的元素中。

{
    "format": "flat",
    "schema": {
        "columns": [
            {
                "name": "TestID",
                "type": "string",
                "xdm": {
                    "type": "string"
                }
            },
            {
                "name": "Name",
                "type": "string",
                "xdm": {
                    "type": "string"
                }
            }
        ]
    },
    "data": [],
    "cdcMetadata": {
      "columnDetected": true
    }
}

後續步驟

按照本教學課程,您已探索您的資料庫、找到您要擷取至Experience Platform的表格路徑,並取得有關其結構的資訊。 您可以在下一個教學課程中使用此資訊,從資料庫收集資料並將其帶入Experience Platform。

自動翻譯
使用「語言選取器」檢視此頁面的英文版。
翻譯是否有幫助?

Ask AI

Not sure where to start?
Ask me anything about Adobe products.

Type your question or pick a suggestion below.

Use of this AI chatbot is subject to Adobe's Privacy Policy. Don't share sensitive data. AI responses are not your Content, may be inaccurate, and any offers provided are non-binding. Generative AI Terms.