News

PgTools: save your time and prevent mistakes when programming in F#

PgTools is an appliance designed to save time and effort in those tasks that make up the "least exciting part of coding", for example, copy & paste or data modification from the database to the project structure.

It takes in developers' timing optimization two key functions: we could define it like an ORM, and -as we explain below- it incorporates database aspects as a bonus.

It’s a Virtusway team development, which promises a significant quality increase of both the code and the final product. Download it at the end of this statement and take advantage of it at no cost.

Data access in F# code

First, PgTools helps using F# to code given a Postgres database, generating persistence entity elements linked to this database, and providing the necessary access methods to implement actions on its tables.

In other words, if we have a database with two tables (let us say users and companies, for example), PgTools establishes data access in F# for this users and companies' tables. At the same time, it creates the users and companies' entities, with their properties, in F# code.

Update scripts

Another remarkable functionality consists in reading the database and in generating templates thereof with the same structures content on it. As a result, if some programmer else wants to locally create or update the database, he can do it taking those templates which include all the changes that have already been made on them.

That is to say, PgTools builds database update scripts, which is especially useful when two or more people are working on the same project. So, all changes are reflected in the database, then they are put into the script and brought into the project.

Let's take an example: we assume that we have three tables and we modify them, and another programmer wants to use it and to work on that project. How do you ensure that you will have the database updated? You need to run Pgtool on the updated database, then you must get the script generated as a result and take it to the database that you want to update.

Gain time and avoid many mistakes

The advantages of this tool are noticeable in any database project, but especially in the large ones with many entities and tables. It saves hours and hours of code separate from business logic programming, which is basically copy, paste and adapt.

The most important thing is that errors are avoided. We have all experienced what happens when some field is renamed in a table and we don’t remember to change it back in the application, or when we leave any field out after copying a table structure to modify the data.

PgTools ensures that these misleads and forgetfulness are no longer a problem, which gives peace of mind and confidence in work to any developer, increasing the final product quality.

Projections

As we have seen so far, PgTools can be applied to any type of Postgres project.

Virtusway is working on including more functions such as the construction of BIZ entities, pure F# entities, API entities, and also UI entities which may even be developed in C#.

In essence, functionalities will be added to improve programming performance.

Here is the download link for PgTools

As you can imagine, we would like to count on your contributions and tests to improve this working tool. So, once you start using it, send us your feedback!

Discover how we can help you

Please leave us your question and one of our assistants will contact you asap.