ODBC Driver for Amazon DynamoDB

Build 23.0.8839

カスタムスキーマ例

このセクションには、完全なスキーマが含まれています。インフォセクションではAmazon DynamoDB テーブルのリレーショナルビューを可能にします。詳細はカスタムスキーマ定義 を参照してください。次のテーブルではSELECT、INSERT、UPDATE、およびDELETE コマンドが以下のスキーマのGET、POST、MERGE、およびDELETE セクションとして実行されます。Location プロパティをスキーマファイルを格納するファイルディレクトリに設定します。

'other:tableapiname' 属性を使って、パースするテーブル名を特定します。'other:tableapiname' 属性を使って、同じコレクションに対して複数のスキーマを定義することができます。 Note: Amazon DynamoDB は大文字・小文字の区別が必要です。テーブル名および指定されたパスは、Amazon DynamoDB においてフィールドが現れる際の大文字・小文字に合致している必要があります。

dynamodbadoProviderOperationCaller のような処理は内部の実行であり、as-is でコピーできます。

<api:script xmlns:api="http://apiscript.com/ns?v1" xmlns:xs="http://www.cdata.com/ns/rsbscript/2" xmlns:other="http://apiscript.com/ns?v1">
  <api:info title="StaticRestaurants" other:catalog="CData" other:schema="AmazonDynamoDB" description="StaticRestaurants" other:tableapiname="StaticRestaurants"  other:version="20">
    <attr   name="id"      xs:type="decimal"   key="true"   columnsize="17"     precision="38"   scale="6"   readonly="false"   description="Dynamic Column."   other:dynamodatatype="N"   other:relativepath="restaurant_id"   other:filterable="true"   other:fullpath="restaurant_id"      other:apiname="&amp;quot;restaurant_id&amp;quot;"                          />
    <attr   name="borough"            xs:type="string"                 columnsize="2000"                                readonly="false"   description="Dynamic Column."   other:dynamodatatype="S"   other:relativepath="borough"         other:filterable="true"   other:fullpath="borough"            other:apiname="&amp;quot;borough&amp;quot;"                                />
    <attr   name="address_zipcode"    xs:type="int"                    columnsize="4"      precision="10"               readonly="false"   description="Dynamic Column."   other:dynamodatatype="S"   other:relativepath="zipcode"         other:filterable="true"   other:fullpath="address.zipcode"    other:apiname="&amp;quot;address&amp;quot;.&amp;quot;zipcode&amp;quot;"    />
    <attr   name="address_coord_0"    xs:type="double"                 columnsize="8"      precision="15"               readonly="false"   description="Dynamic Column."   other:dynamodatatype="N"   other:relativepath="coord"           other:filterable="true"   other:fullpath="address.coord[0]"   other:apiname="&amp;quot;address&amp;quot;.&amp;quot;coord&amp;quot;[0]"   />
    <attr   name="address_coord_1"    xs:type="double"                 columnsize="8"      precision="15"               readonly="false"   description="Dynamic Column."   other:dynamodatatype="N"   other:relativepath="coord[1]"        other:filterable="true"   other:fullpath="address.coord[1]"   other:apiname="&amp;quot;address&amp;quot;.&amp;quot;coord&amp;quot;[1]"   />
    <attr   name="address_building"   xs:type="int"                    columnsize="4"      precision="10"               readonly="false"   description="Dynamic Column."   other:dynamodatatype="S"   other:relativepath="building"        other:filterable="true"   other:fullpath="address.building"   other:apiname="&amp;quot;address&amp;quot;.&amp;quot;building&amp;quot;"   />
    <attr   name="address_street"     xs:type="string"                 columnsize="2000"                                readonly="false"   description="Dynamic Column."   other:dynamodatatype="S"   other:relativepath="street"          other:filterable="true"   other:fullpath="address.street"     other:apiname="&amp;quot;address&amp;quot;.&amp;quot;street&amp;quot;"     />
    <attr   name="name"               xs:type="string"                 columnsize="2000"                                readonly="false"   description="Dynamic Column."   other:dynamodatatype="S"   other:relativepath="name"            other:filterable="true"   other:fullpath="name"               other:apiname="&amp;quot;name&amp;quot;"                                   />
    <attr   name="cuisine"            xs:type="string"                 columnsize="2000"                                readonly="false"   description="Dynamic Column."   other:dynamodatatype="S"   other:relativepath="cuisine"         other:filterable="true"   other:fullpath="cuisine"            other:apiname="&amp;quot;cuisine&amp;quot;"                                />
  </api:info>


  <api:script method="GET">
    <api:call op="dynamodbadoProviderOperationCaller">
      <api:push/>
    </api:call>
  </api:script>

  <api:script method="POST">
    <api:call op="dynamodbadoProviderOperationCaller">
      <api:push/>
    </api:call>
  </api:script>

  <api:script method="MERGE">
    <api:call op="dynamodbadoProviderOperationCaller">
      <api:push/>
    </api:call>
  </api:script>

  <api:script method="DELETE">
    <api:call op="dynamodbadoProviderOperationCaller">
      <api:push/>
    </api:call>
  </api:script>
</api:script>

Copyright (c) 2024 CData Software, Inc. - All rights reserved.
Build 23.0.8839