What is TAAS?
The table as a service is a helpful way of high frequency, high volume data exchange, Dynamics 365 finance and operations, without having to worry about supporting architecture, agility, and efficiency. I can make my data be stored and arranged as per any need, without sticking to fixed metadata, beforehand – as compared to conventional DBMS definition. Your Table exists as an API, whereby you can call the API and enforce PUT, POST and delete actions thereby.
Table as a service as a storage
Azure table storage exists as a patterned NoSql data in Azure, resulting in a schema-less design.
Table storage generally comprises of following components:
- Accounts: a subscription account that connects all the storage offerings(Blobs/files, queues, containers, tables)
- Tables: a table can comprise of several entities
- Entities: an entity is like a row that comprises of several properties
- Properties: Key-value pair
Look at the following example that comes from a TAAS on a successful creation:
The above example results from an attempt to write into a table, with fields AcqMethod and Description. PartitionKey and RowKey are unique key pairs. Here the record exists as a property (starting from d:PartitionKey to d:Description). The table does not have any fixed schema as contrary to our concept of RDBMS.
Creating a table storage
Step 1:
Navigate to ~\Home\All services\Storage accounts\admin storage account. Choose from ‘Tables’.
Step 2:
Create a new table → give a table name(avoid using ‘_’ or special characters). Press OK to to continue.
This would result in creating your table. See the adjoining URL, implying that it exists as an endpoint API.
Step3:
Shared access signature (SAS):
A shared access signature is an easy way common palette of data access for various modes of data storages: Blob, Queues, Tables, or containers.
Navigate to left hand pane → Shared access signature → Generate SAS and Connection string button. Tick on ‘Table’ → to create Keys for Table. Also click on the necessary allowed permissions:
This will generate the following access key/connection strings:
Querying your table from Postman:
Copy the ‘Table service SAS URL’ → Open postman → paste it in the browser → amend to include the table name you have created between ? and the last ‘\’ → do a ‘GET’ → Send
It will result in the records of the table as an XML’s key value pair dataset:
Note: how the name of the table has been given at the end of the SAS key.
Viewing from Azure browser
You can download Azure browser from:
https://go.microsoft.com/fwlink/?LinkId=708343&clcid=0x4009
You can install the storage explorer. It’s an ultimate tool to upload, download, maintain and query your storage contents – just like the older days of SSMS.
Browse down to → on the left hand pane Subscription name → Storage accounts → created table:
You can query quite easily using query button from above:
Using logic apps: integration
Logic apps could be used successfully as a messenger exposing your Table Services to expose, interpret/Parse and consume data. You can highlight your table as a service and then write a trigger to fire when data arrives on your table as an HTTP request.
Steps:
a. Figure out an HTTP request with the following JSON payload as its sample payload:
b. You can optionally choose a ‘compose’ action from above result.
c. Add an action as ‘Insert entity’ by choosing from ‘Table storage’ connecter.
d. Choose from step-b, choose from the Table that you have created (evidently it relates the set of tables available from the same azure subscription.
e. Add a ‘Get entity’ action → it acts like an query, select the table you created and ‘PartitionKey’ and ‘RowKey’ values from the payload defined on Step-a.
So as a result the code for the logic app looks like:
@{outputs('Compose')}
", "contentType": "html" } } , "host": { "connection": { "name": "@parameters('$connections')['teams']['connectionId']" } } , "method": "post", "path": "/v3/beta/teams/@{encodeURIComponent('*****')}/channels/@{encodeURIComponent('***@thread.skype')}/messages" } , "runAfter": { "Get_entity": [ "Succeeded"] } , "type": "ApiConnection" } } , "contentVersion": "1.0.0.0", "outputs": {} , "parameters": { "$connections": { "defaultValue": {} , "type": "Object" } } , "triggers": { "manual": { "inputs": { "schema": { "properties": { "AcqMethod": { "type": "string" } , "Description": { "type": "string" } , "PartitionKey": { "type": "string" } , "RowKey": { "type": "string" } } , "type": "object" } } , "kind": "Http", "type": "Request" } } } , "parameters": { "$connections": { "value": { "azuretables": { "connectionId": "/subscriptions/****/resourceGroups/****/providers/Microsoft.Web/connections/azuretables", "connectionName": "azuretables", "id": "/subscriptions/*****/providers/Microsoft.Web/locations/westus/managedApis/azuretables" } , "teams": { "connectionId": "/subscriptions/****/resourceGroups/****/providers/Microsoft.Web/connections/teams-1", "connectionName": "teams-1", "id": "/subscriptions/****/providers/Microsoft.Web/locations/westus/managedApis/teams" } } } } }The logic app gives the following outcome, when fired from Postman:
Conclusion
Further mastery of dynamics 365 for finance and operations team shares this document on the table as a service: Create a data integration strategy. This team owns helps to grow your business to the best of its ability.