Like

Welcome On Mobius

Mobius was created by professionnal coders and passionate people.

We made all the best only for you, to enjoy great features and design quality. Mobius was build in order to reach a pixel perfect layout.

Mobius includes exclusive features such as the Themeone Slider, Themeone Shorcode Generator and Mobius Grid Generator.

Our Skills

WordPress90%
Design/Graphics75%
HTML/CSS/jQuery100%
Support/Updates80%

Create Azure Logic App Using SQL Connectors

By Inaam Ur Rehman 1 year agoNo Comments

In BizTalk Server, SQL Adapter is the main component in order to communicate with the SQL Server. On the other hand, In Logic App we use connector to communicate with the SQL server. In this tutorial we will create a table in SQL Azure and perform read and write operations using logic app.

 

Pre-requisites:

  • Azure subscription, if you don’t have a subscription, you can start with the free subscription here .

Get Your Free Beginner’s Logic Apps Training Guide 

Create table in SQL Azure:

 

  1. Login to Azure Portal.
  2. Click on SQL Database > Add.
  3. Enter database name and select your subscription and resource group. Select Source as a Blank Database and click on Server. A new section named “Server” would be appear. Click on Create a new Server or you can select existing server.
    1. In case of New Server, Enter any name in the Server name field and Server admin login field. Type any password and click on select. Please remember these credentials for now.
  4. Enter on Create button a new database would be created
  5. Click on your database > Overview > Tools > Query editor(Preview) and execute following query in the query window.

CREATE TABLE ingredient ( ingredientId INT primary key IDENTITY(1,1) NOT NULL,

ingredientName VARCHAR(50) NOT NULL,

ingredientPrice INT NOT NULL

);

INSERT INTO ingredient

( ingredientName, ingredientPrice)

VALUES

(‘Beef’, 3),

(‘Mango’, 2),

(‘Cheese’, 4);

 

Note: If you are unable to the execute query then click on Login on the top of query window and provide your credentials which we created earlier.

 

  1. Create another table with the same structure. So we can dump data from the ingredient table to a new table.

Limitations:

Table must have an Identity column.

Logic App to import data from one table to another table:

  1. Go to the Azure portal again.
  2. From the left azure menu, choose New > Enterprise IntegrationLogic App.
  3. Add your Logic App name and select your subscription. Add new or use existing resource group. Resource group helps you to manage all the related resources in one resource group. Mark pin to dashboard if you want and click on the create.

 

 

  1. Select a blank logic app from templates.
  2. Type SQL as a filter in search box and select SQL Server – When an item is created
  3. If you are not connected already, click on Manually enter connection information. Enter all the connection information like undermentioned in figure.

 

  1. Connection Name is just like connection string name. You can use the same connection in other logic apps.
  2. Once you entered the information, click on the create button.

 

  1. Now choose an action to dump data to new table. At the bottom of trigger, choose + New Step > Add an action.
  2. Provide the table name, and set the interval and frequency for recurrence. In the screenshot I have set an internal of three minutes.

 

 

  1. Type SQL as filter again, and select SQL Server – Insert row from action list.
  2. Select table name. All table columns would be shown as text boxes.

 

 

  1. Set value to text boxes, you can add static or dynamic values from previous actions.
  2. Now you can run this Logic App.
Category:
  Logic Apps
this post was shared 0 times
 000
About

 Inaam Ur Rehman

  (9 articles)

Inaam ur Rehman is a Senior Software Engineer in Allied Consultants. With a experience over 3 years in ASP.Net, SharePoint, BizTalk, Java Script and JQuery . He is one of the key resources of ASP.Net for the organization.

Leave a Reply

Your email address will not be published.