建立新結構描述 create-new-schema
若要編輯、建立及設定方案,請按一下 Administration > Configuration > Data schemas Adobe Campaign使用者端主控台的節點。
此 Edit 索引標籤顯示架構的XML內容:
此 Preview 索引標籤會自動產生擴充型架構:
如果您需要檢查架構的完整結構,可以使用 Preview 標籤。 如果結構描述已擴充,您就能將其所有擴充功能視覺化。 作為補充, Documentation 頁簽會顯示所有綱要屬性和元素,及其特性(SQL欄位、型別/長度、標籤、說明)。 此 Documentation 標籤僅適用於產生的結構描述。
使用案例:建立合約表格 example--creating-a-contract-table
在下列範例中,您會為 合約 在資料庫中。 此表格可讓您儲存每個合約的持有者和共同持有者的名字和姓氏,以及電子郵件地址。
要執行此操作,您需要建立表格的綱要,並更新資料庫結構以產生對應的表格。 詳細步驟列於下方。
-
編輯 Administration > Configuration > Data schemas Adobe Campaign樹的節點,然後按一下 New.
-
選擇 Create a new table in the data template 選項並按一下 Next .
-
指定資料表的名稱和名稱空間。
note note NOTE 依預設,使用者建立的方案會儲存在「cus」名稱空間。 有關詳細資訊,請參閱 結構描述的識別. -
建立表格內容。 我們建議使用專用助理來確認沒有遺失任何設定。 若要這麼做,請按一下 Insert 按鈕,並選擇要新增的設定型別。
-
定義合約表格的設定。
根據最佳實務,請在雲端資料庫中新增表格
dataSource="nms:extAccount:ffda"
屬性。 建立新表格時,預設會新增此屬性。code language-none <srcSchema created="YYYY-MM-DD HH:MM:SS.TZ" desc="Active contracts" img="crm:crm/mscrm/mscrm_account_16x16.png" label="Contracts" labelSingular="Contract" lastModified="YYYY-MM-DD HH:MM:SS.TZ" mappingType="sql" name="Contracts" namespace="cus" xtkschema="xtk:srcSchema"> <element dataSource="nms:extAccount:ffda" desc="Active contracts" img="crm:crm/mscrm/mscrm_account_16x16.png" label="Contracts" labelSingular="Contract" name="Contracts"> <attribute name="holderName" label="Holder last name" type="string"/> <attribute name="holderFirstName" label="Holder first name" type="string"/> <attribute name="holderEmail" label="Holder email" type="string"/> <attribute name="co-holderName" label="Co-holder last name" type="string"/> <attribute name="co-holderFirstName" label="Co-holder first name" type="string"/> <attribute name="co-holderEmail" label="Co-holder email" type="string"/> <attribute name="date" label="Subscription date" type="date"/> <attribute name="noContract" label="Contract number" type="long"/> </element> </srcSchema>
新增合約分項清單的型別。
code language-none <srcSchema created="AA-MM-DD HH:MM:SS.TZ" desc="Active contracts" img="crm:crm/mscrm/mscrm_account_16x16.png" label="Contracts" labelSingular="Contract" AA-MM-DD HH:MM:SS.TZ"mappingType="sql" name="Contracts" namespace="cus" xtkschema="xtk:srcSchema"> <enumeration basetype="byte" name="typeContract"> <value label="Home" name="home" value="0"/> <value label="Car" name="car" value="1"/> <value label="Health" name="health" value="2"/> <value label="Pension fund" name="pension fund" value="2"/> </enumeration> <element dataSource="nms:extAccount:ffda" desc="Active contracts" img="crm:crm/mscrm/mscrm_account_16x16.png" label="Contracts" labelSingular="Contract" name="Contracts"> <attribute name="holderName" label="Holder last name" type="string"/> <attribute name="holderFirstName" label="Holder first name" type="string"/> <attribute name="holderEmail" label="Holder email" type="string"/> <attribute name="co-holderName" label="Co-holder last name" type="string"/> <attribute name="co-holderFirstName" label="Co-holder first name" type="string"/> <attribute name="co-holderEmail" label="Co-holder email" type="string"/> <attribute name="date" label="Subscription date" type="date"/> <attribute name="noContract" label="Contract number" type="long"/> </element> </srcSchema>
-
儲存結構描述,然後按一下 Structure 標籤以產生結構:
-
更新資料庫結構以建立將連結綱要的表格。 如需詳細資訊,請參閱本章節。