leandrovip / Vip.SqlQuery

Simple library for generate sql queries to MS SQL SERVER

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Vip.SqlQuery

License NuGet NuGet Downloads


This is a very simple library to generate SELECT queries in SQL SERVER. It is possible generate queries with many columns, prefix, many possibles where´s clause, parameters and more. ✌️ 😉

Requirements

.Net Standard 2.0

How to use ?

Declare a using:

using Vip.SqlQuery;

Code:

var query = SqlQuery.New()
    .Select(new[] {"ProductId" "Product", "Description", "Price", "p"})
    .From("Product p")
    .OrderBy("p.ProdutoId")
    .Build();

Query return:

Console.Write(query.Command)

/*
SELECT [p].[ProductId], [p].[Product], [p].[Description], [p].[Price]
FROM [Product] [p]
ORDER BY [p].[ProdutoId]
*/

License

MIT

About

Simple library for generate sql queries to MS SQL SERVER

License:MIT License


Languages

Language:C# 100.0%