Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview

In this document lesson we will explain how to verify if Stored Procedures are synchronized between our DB database and Wayfast. This objects are going to be used with in the different objects functions like Actions, Dataset and Controls depending on the environment that Wayfast users we are going to develop the application.

How to verify if Stored Procedure is associated to Wayfast?

Info

Stored Procedure: This is an object in

...

database that we can create manually in SQL Server Management Studio

...

. This will allow developers to make inquiries and modify our data given certain procedures.  

Click on Database” icon at the top header.

...

Grid view is displayed on screen with all the Stored Procedures associated to our Project. You can observed that the “Object Name” will be the Stored Procedure identification and “Database” column will let us know to which database is associated.

How to create a Stored Procedure and synchronize to Wayfast?

Precondition

On Wayfast, make sure that the Project is created and make a Requirement into “Active” status by clicking on “Active Task” button at Navigation left side navigation bar.

...

Note

NOTE: This requirement should always be associated to the DB database instance from the Project. We will verify later that Wayfast can associate new stored procedures from other DBs databases without using an active requirement.

Click on “Database” icon at the top headermenu.

...

On Submenu, selects “Stored Procedure” subtab

...

We can proceed to create a new Stored Procedure in SQL Server

...

Code Block
languagesql
CREATE TABLE Test_Employee(
--Id  int identity(1,1) NOT NULL,
Name  nvarchar(50)  NULL,
Role  nvarchar(50)  NULL,
Date  datetime      NULL
)

Code Block
languagesql
CREATE PROCEDURE SP_Add_Employee
  @Name  nvarchar(50)  =NULL,
  @Role  nvarchar(50)  =NULL
AS
  BEGIN
      INSERT  Test_Employee(Name,Role,Date)
      SELECT  @Name,@Role, GETDATE()
  END
GO

Once that the new Table and Stored Procedure are created, we can go to Wayfast application.

...

Click on “End Task” button related to Project’s requirement. This step is only needed for synchronization of the new Table and Stored Procedure generated in DBdatabase.

...

Now we have the new objects available in Wayfast Application.

...

Notice that the new Stored Procedure is displayed in Grid View.

How to associate a Stored Procedure from a different DB?

Precondition

On Wayfast, make sure that the Project is created and click “End Task” button in case you have an “Active” Requirement at Navigation left side navigation bar.

Note

NOTE: Also we We need to make sure that these foreign databases are linked to the Project as well as Instances.

...

A popup is displayed to change the requirement status

...

Automatically a new “Associate SPs” button is enable on screen. Click on it“Associate SPs”

...

A popup is displayed to make the association between the new object. There are 2 options to associate SPs stored procedures into our Project:

  • Simple

  • Multiassign

...

Multiassign option allow us to select multiple Stored Procedures at the same time from the same Instance and Database.

...

Clicking Checking the checkbox, Wayfast will save the association and list all the selected objects in Stored Procedure Procedure’s dashboard.

Recap

In this documentlesson, we learn learnt how to associate new Stored Procedures created in SQL to our Project’s database. And Also we observed how Wayfast allows us to search other objects that were not generated specifically to the Project but that can be available in case you we want to use itthem. These foreign objects can only be associated if Project doesn’t have an active requirement in Wayfast and also if the Instance and Database are related like we explained in previous documents through General Optionslessons.