Does Phinx help in query building - phinx

I'm trying to use PHINX as database query builder for SQL database. Does Phinx help only database migrations?
The document also has only about configuration and steps for migration.
https://phinx.org/
http://docs.phinx.org/en/latest/

From the documentation you posted:
Phinx is just about migrations without all the bloat of a database
ORM system or application framework
PHP has many options for ORMs, such as Redbean, Doctrine and my favorite, Eloquent (comes with Laravel)

Related

What is a good action plan for database first connect data from postgresql to a c# project with dot net core and using entity framework core

I need to successfully do database first connect data from postgresql to a c# project with dot net core and using entity framework core.
Am familiar with mvc with sql and entity framework full database first (in this case we use the Entity Data Model Wizard which makes things easier.
I am not familiar with EFcore, dot net Core and also postgresql.
I successfully did a code first connect data from postgresql to a c# project with dot net core and using entity framework core, and using npgsql, on a console app.
Now I need to do database first web application, and should I try to edit my existing code first console app to try database first? Or should I build a new mvc project from scratch?
Also, if I do from scratch, what will be a good sequence I try
eg 1. try entity framework core tutorial first (which uses sql and is only code first),
then2. try to see how to do database first using reverse engineering
then3. try to replace the sql with postgresql
or are there any other methods that are better?
Scaffolding works with postresql.
Create project which will have your database entities and context. Install efcore tools and npgsql for this project.
Then, inside new project try this command using cmd:
dotnet ef dbcontext scaffold "Host=localhost;Database=databaseName;Username=user;Password=password" Npgsql.EntityFrameworkCore.PostgreSQL -t table1 -t table2 -o outputFolder
You dont have to pass -t parameters if you want to scaffold whole database.
If some error happens, try --force argument.
You should be able to use this database via context created by ef core.

MongoDbContext for data migration in EF core?

Currently I'm trying to find a method to use EF core 2.2 for data migration. After reading the instruction at:
https://learn.microsoft.com/en-us/ef/core/managing-schemas/migrations/
I realise that it only support DbContext.
At the moment, in my project I have mongoDBContext and IMongoDBContext for my database and I couldn't find any package that support them. I also try using Microsoft.EntityFrameworkCore.Design but it's not helping. Is there any solution for me to use mongoDbContext as the database provider, or any packages that support mongoDB as the database provider?
As for my attempt to create a migration file despite not having DbContext:
From my terminal
dotnet ef migrations add InitialCreate
Error
No DbContext was found in assembly '.Data'. Ensure that you're using the correct assembly and that the type is neither abstract nor generic.
Thank you so much!
MongoDb is schema-less storage.
Entityframework Migrations is use to update schema of the tables. Yes migrations can also run update/delete/insert part of migration but only because Sql is dependent on schema.
In addition EF is not supporting MongoDb since mongo db is not using sql, mongo db has his own api/language.
Yes recent updates of EFCore supports CosmosDb but only because CosmosDB can talk sql
To sum up.
If you need to modify schema probably your MongoDb design is wrong.
If you want to talk to MongoDb use https://docs.mongodb.com/ecosystem/drivers/csharp/
If you are not familiar with MongoDb use what you familiar with
Yes, Mongodb is shema-less storage. But a solution always has some sort of schema in your POCO/DDD typed/dynamic objects and related domain logic. And you may change these contracts over time. So with Mongo we have the ability to perform two types of migrations: upgrade scripts ( like with RDBMS) or on-the-fly document migration when documents are used. You definitely can use your MongoDB without changes in existing documents in projects like collections of metrics and IoT device data or highly dynamic objects but this is not always the case.

migration existing schema of titan db

Need help in migrate existing titan DB instance ,schema with data to another running titan DB instance in another server .
We created Titan DB instance (schema) using 0.5.4 version.
Is there any API provided by titan for migration ?
Thanks in advance
There are no push-button migration utilities in the Titan API. Most of the time, users write migration scripts in groovy to do data migrations. This might entail use of titan-hadoop in 0.5.4 or BLVP in Titan 1.0. In your situation, it doesn't sound like you need any of that. Just copy the data files of berkeleydb from your original server to your new server.

SQLite or SQL Server CE for Entity Framework migrations?

I'm starting a project and I will need to use the migrations provided by Entity Framework 6.
I found that SQLite does not have support for migrations.
SQL Server CE is the better option if I need to use the code-first migrations, or do I have other choices?
Remembering, I need a self-contained database engine.
No other choices, as far as I know

Entity framework PostgreSQL

Can someone tell me how can I get MS Entity Framework working with PostgreSQL.
Also: How does Entity Framewok work with Mono? Could you please suggest other similar ORM tools which would run on Mono and what is your opinion about them?
Entity framework also works with Npgsql - .Net Data Provider for Postgresql.
A tutorial on how to set it up can be found here:
http://www.npgsql.org/ef6/index.html
Devart has a product that gives entity framework support for PostgreSQL. See:
http://www.devart.com/dotconnect/postgresql/
There is a provider for mono for postgreSQL. See:
http://www.mono-project.com/PostgreSQL