Category "orm"

Typeorm. use only the date part while querying via date and exclude the timestamp part

I have a use case where I have to retrieve a users record from the database via his date of birth. The thing is that we have stored the date of birth of the use

Node Js sequelize select query by month

Am new in Node Js, In my Node Js project am using sequelize ORM with MySql database. This is my query i want to write select query by month. This is my query

.NET Core Entity Framework how to map nested class into one sql table

I'm still new to .NET Core. I have this character that I want to store in SQLite using an entity. But by default, Character, CharacterData and CharacterLine are

SilverStripe unable to populate multiple member Childs

I have 3 type of users salesman => has many buyers buyer => has many agents agent has none child so I want to list all the buyers associate with that sale

SQLAlchemy: What is the best way to validate a model before inserting or updating

I'm trying to validate a SQLAlchemy model before it is inserted or updated, e.g class MyModel(db.Model): foo = db.Column(db.String(255)) bar = db.Colum

How to consolidate TypeORM migrations

At the moment I'm not a guru on TypeORM and have made a few mistakes with my migrations - with our non-production database now in a state where I'd like it, is

Many-to-many relationship with parent with two releationships to same child

I'm trying to model a simple (at least I thought so) relationship like in a recipe (I'm using flask-sqlalchemy): I have a Recipe, that has input materials and o

How to build query from SQL by Doctrine QueryBuilder?

I'm new in Doctrine ORM, and I need help with building QueryBuilder command. I have a SQL command and I need covert to QueryBuilder. $qb = $this->entityManag

Error executing DDL "drop table Player if exists" via JDBC Statement

Creating a spring mvc project with database using java configuration . The application gives error for tables operation like create, drop, alter operation for

Room field / getter mismatch warning when using sealed classes or Any

I have a Room (v2.4.0-beta01) database, and whilst it works fine, during the build it gives a field vs getter mismatch warning on a few fields, included below.

Hibernate 6: What is SQM?

In the Hibernate 6.0 Roadmap (https://github.com/hibernate/hibernate-orm/wiki/Roadmap6.0) SQM is mentioned as upcoming. What is SQM? In this roadmap the follo

Sequelize ARRAY Datatype for PostgreSQL

I'm trying to use the ARRAY datatype for Sequelize (Node.js SQL ORM) with PostgreSQL. However I'm not exactly sure how to utilize it. I know how to set it on th

How to give a unique constraint in lucid model, I am using lucid in adonis with typescript

In adonis.js i am trying to add a unique constraint to email field just like we do it in sequelize,prismajs or any other orm.Is it posible to add in adonis.

Does TypeORM supports raw SQL queries for input and output?

I would like to know if there is a feature of TypeORM that supports raw sql queries for Insert Update Delete Select etc..

How to remove default value in model and add alembic version?

I am having a pyramid application which uses sqlalchemy and alembic for databases and migrations. I need to remove default specifier from my model class and add

How to Make Laravel Eloquent "IN" Query?

I want to make query in Laravel Eloquent like here its raw MySQL query SELECT * from exampleTbl where id in(1,2,3,4) I have tried this in Laravel Eloquent

Sequelize: can you use hooks to add a comment to a query?

Heroku recently posted a list of some good tips for postgres. I was most intreged by the Track the Source of Your Queries section. I was curious if this was som

Laravel Eloquent vs DB facade: Why use Eloquent and decrease performance? [closed]

I did some performance tests between Laravel's DB facade query builder and Laravel's Eloquent ORM. The DB facade was much faster than Eloquent

flask-sqlalchemy or sqlalchemy

I am new in both flask and sqlalchemy, I just start working on a flask app, and I am using sqlalchemy for now. I was wondering if there is any significant benef

'Source code does not match the bytecode' use IDEA debug JdbcTemplate

When I debug the JdbcTemplate sourcecode use IDEA,the IDE tips me:'Source code does not match the bytecode' Screenshot: and i use mvn to manage m