Introduction

Developing an application from zero in record time and with the minimum functionalities is a great challenge today for developers. In the database, we need tools that help us develop faster and easier according to our needs. It helps us to build a simple skeleton to implement database objects faster to add logic as needed for the application. This code can be customized to add new functionalities.

Background

There are many tools for generating or creating code for SQL Server. Some are free to use while others are paid. However, these types of tools are limited in the sense that you can not modify or add new features according to your needs. For the development of our projects, the intention of this code is to enable you to build faster, easier, and integrate more functionalities as you need it.
The code generator for SQL Server is developed with Transact-SQL in DML (Data manipulation language). It does not depend on other software for its operation or obtaining SQL code, where you can modify or add new functionalities to the code for your needs and objectives, with the aim of developing a database object faster without wasted time. The code is generated by tables in this first version, the database objects that are generated are the following:

Using the code

It is easy and simple to use the SQL Server code generator script, it does not imply making large configurations, because it is developed in Transact-SQL for SQL Server, with the following steps,
  1. Open an instance of “Microsoft SQL Server Management Studio” (SSMS).
  2. Open the .sql file: "Code generator script for SQL Server.sql".
  3. Enter the name of the "Database" where it contains the table to generate the desired code.
  4. Enter the name of the "Table".
  5. Optional, you can add "comments" or leave it empty.
  6. Click on the "F5" or "Execute" key, the SQL Server code generator script will be executed.
  7. Get a "result" to take the code snippet of interest for your work.
Code Generator For SQL Server

Points of interest

Working to improve the code and add new functionalities for the generator code for SQL Server.
Working on code generators for other databases, such as MySQL.
History
Code Generator for SQL Server - Version 1.1.0 - January 2020 - First version