The first step in the CI/CD pipeline involves deploying a database to a local or remote SQL Server
and generating a NuGet package from a source control repository. Building a runnable instance is a
fundamental phase in the project development process.
dbForge Studio for SQL Server plays an essential role in streamlining this process by giving the possibility to automate the step.
Use the Invoke-DevartDatabaseBuild PowerShell cmdlet to organize the Build stage of your project.
The successful completion of this phase is a successfully created database.
After the test database has been built, it needs to be populated with realistic test data. dbForge Studio for SQL Server will perform this task in a few clicks. To organize this step, call the
Invoke-DevartPopulate PowerShell cmdlet. Automating data provisioning for test databases is an important stage in the database development cycle.
Performing unit tests against the objects in the test database is a crucial stage as testing
ensures that certain functionality meets all the requirements or works properly after various
changes made. Use the Unit Test functionality of dbForge Studio for SQL Server to design unit tests and install the test
framework. To automate this step, utilize the
Invoke-DevartDatabaseTest PowerShell cmdlet.
Keep your database documentation complete by automating the process of documentation generation with dbForge Studio for SQL Server. To document your database, use the
New-DevartDatabaseDocumentation PowerShell cmdlet. As a result, you receive extensive database information including inter-object
dependencies and DDL codes in one of the three output formats – HTML, PDF, or Markdown.
Before moving on to the final phase you need to prepare a package for deployment by creating
a database scripts folder and then generating a NuGet package, which will be used as a source
for deployment. Continuous Delivery implies that this step should be automated to ensure a reliable delivery
to users. To create a NuGet package, containing the validated database source, use the
Publish-DevartDatabaseProject PowerShell cmdlet.
The stage involves creating a schema synchronization script after comparing the source in the
NuGet package containing database changes with the target database awaiting the update.
This script will be then used for the release. At this stage, you can use the
Invoke-DevartSyncDatabaseSchema PowerShell cmdlet.
Successful completion of this phase is a successfully created database schema synchronization script.
Importing data to a test database is an important step that can be used at different stages
of the CI/CD process. To perform the task, you can use the Data Import functionality of dbForge Studio for SQL Server that supports
import from 10 widely used data formats and includes a number of advanced options and templates
for recurring scenarios. You can also call the
Invoke-DevartDataImport PowerShell cmdlet to import data
from the Command line.
During the database development cycle, you may encounter a situation when you need to extract
data from a production database quickly and efficiently. To cope with this task, you can use
the Data Export functionality of dbForge Studio for SQL Server that allows exporting data to 14 commonly-used SQL Server data formats.
You can also call the
Invoke-DevartDataExport
PowerShell cmdlet to export data from the Command line.
After completion of all the stages above, you can proceed to publish the NuGet package to the NuGet repository to share it with your team, organization, or customer. This stage is highly important as the CI/CD pipeline requires side-to-side collaboration between the Development, Test, and Operations teams. To publish a NuGet package from the command line, call the
Publish-DevartDatabaseProject PowerShell cmdlet.