EzDbSchema 7.0.0

dotnet add package EzDbSchema --version 7.0.0
NuGet\Install-Package EzDbSchema -Version 7.0.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="EzDbSchema" Version="7.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add EzDbSchema --version 7.0.0
#r "nuget: EzDbSchema, 7.0.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install EzDbSchema as a Cake Addin
#addin nuget:?package=EzDbSchema&version=7.0.0

// Install EzDbSchema as a Cake Tool
#tool nuget:?package=EzDbSchema&version=7.0.0

EZDBSchema - Easy Database Schema

A class library that alllows you to point to a database and obtain a schema dump complete with columns, relationships (including fk names and multiplicity). Some use cases require a schema of a database without the bulk of Entity power tools or Entity Framework.

Included in the project is a handy command line interface that can be used to dump the schema of the database to a json file.

The idea is to obtain the database schema informtion as close to the source as possible. All of the schema definitions can be obtain from the database itself, with a little sluething, we can derive that information we need quickly and deliver it into a usable object heirarchy.

One possible use of this is for code generation based on database objects.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

You will need MSSQL with some database installed. If you need a sample database, feel free to look for the World Wide Importers samples.

Using this project:

From NuGet
  1. Install-Package EzDbSchema.Core
  2. Add the following line of code
var schema = new EzDbSchema.MsSql.Database().Render("MySchema", "Server=???;Database=???;user id=sa;password=sa");
  1. Run the app
As Cli
  1. Change EzDbSchema.Cli/appsettings.json ConnectionString to the proper database authentication credentials.
  2. run the application. A file called MySchemaName.db.json will be written to the EzDbSchema.Cli folder

Deployment

This project was design to be hosted and distributed with nuget.com.

Built With

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Acknowledgments

Many thanks to the following projects that have helped in this project

  • McMaster.Extensions.CommandLineUtils

Release Notes

V 7.0.0 - Nuget package upgrades, updated to .net 7.0

V 6.0.1 - Added the ability to tell the generator to not auto create the primary keys if they are missing

V 6.0.0 - Migration to .net 6.0

Product Compatible and additional computed target framework versions.
.NET net5.0 is compatible.  net5.0-windows was computed.  net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 is compatible.  netcoreapp3.0 was computed.  netcoreapp3.1 is compatible. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 is compatible. 
.NET Framework net461 is compatible.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 is compatible.  net48 is compatible.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on EzDbSchema:

Package Downloads
EzDbCodeGen

This complete and self contained code generation utility will install in a sub directory EzDbCodeGen of a target project. From this path, you can run a powershell script that will generate code based on the connection string. Each template is a handlebars template that has tags that specify where you would like to output the generated code and if there is a vs project that you wish to update with the file list (old VS project formats only).

EzDbCodeGen.Core

This will install a local cli tool. From this path, you can run a powershell script that will generate code based on the connection string. Each template is a handlebars template that has tags that specify where you would like to output the generated code and if there is a vs project that you wish to update with the file list (old VS project formats only).

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
7.0.0 348 1/2/2023
6.0.1 736 4/27/2022
6.0.0 6,655 11/23/2021
5.0.9 358 9/7/2021
5.0.8 315 9/6/2021
5.0.7 416 6/20/2021
1.0.53 1,035 5/13/2020
1.0.31 1,669 12/21/2019
1.0.29 539 8/30/2019
1.0.28 1,424 6/6/2019
1.0.27 563 6/5/2019
1.0.26 761 2/22/2019
1.0.23 848 8/24/2018
1.0.22 789 8/20/2018
1.0.21 845 8/16/2018
1.0.16 830 8/1/2018
1.0.15 855 7/27/2018
1.0.11 4,995 7/20/2018

Updated all Nuget packages and added .net 7