8,776 questions
0
votes
0
answers
40
views
Multiset for many to many relation in sqlalchemy using an associative table
I have a situation where I have 2 tables with a many to many relationship
class Book(MyBaseClass):
book_id: Mapped[int] = mapped_column(primary_key=true)
words: Mapped[List[Word]]
class Word(...
Best practices
1
vote
4
replies
62
views
Should resume skills be stored as JSON, BLOB, or normalized tables for analytics and search performance?
Should resume skills be stored as JSON, BLOB, or normalized tables for analytics and search performance?
I'm building a resume analyzer that extracts skills and stores them for analytics. Currently ...
1
vote
0
answers
96
views
Django ManyToMany self relationship with through model — user_from and user_to reversed behavior
I added following and followers by using intermediate model, it's ok but does not correctly specify objects in the intermediate model. I expect the user who follows must to be in the user_from field ...
Advice
0
votes
2
replies
53
views
How to set the value in the basic many-to-many relationship example of EF?
Here's a basic example from the official .NET documentation for a many-to-many relationship using EF and .NET:
public class Post
{
public int Id { get; set; }
public List<Tag> Tags { get;...
0
votes
1
answer
116
views
How do I join and select from a many-to-many relation?
I have tables Properties and Features with many-to-many relationship PropertiesFeatures (which holds their IDs):
When I select multiple features (feature IDs) as an array, I need all properties which ...
0
votes
0
answers
78
views
Spring boot (Java) ManyToMany 415 error when sending POST
I have the most basic ManyToMany example, Project and Employee.
With a PUT request, I will project to employee and within the same function employee to project.
public Employee assignProjectToEmployee(...
0
votes
0
answers
101
views
What is the correct syntax for querying many-to-many relationships in FetchXML when the intersect table is not directly accessible?
I'm trying to retrieve related equipment records from a test record using FetchXML in Dataverse. There is a many-to-many relationship between the test table and the equipment table.
A join (intersect) ...
0
votes
2
answers
174
views
Insert record into many-to-many relationship [duplicate]
I want to create a database for my blog website where I have many posts and categories. A post can have many categories and a category can have many posts. I couldn't figure out how to implement it in ...
1
vote
1
answer
72
views
Querying Many-to-Many relations in Prisma
I have following schema.prisma generated from existing db structure:
model accounts {
account_id Int @id(map: "accounts_pkey1") @default(autoincrement())
account_uid String @...
3
votes
1
answer
88
views
How to query models with a where condition on the pivot table using a many-to-many relationship?
I have two models, User and Role. These two models have many-to-many relationship between each other with pivot table role_user. In this pivot table are values user_id, role_id and meta_value. ...
0
votes
0
answers
354
views
In HotChocolate 15, how to use projection and data loader for many to many relationship?
I'm using Hotchocolate v15, EF Core. For 1:m relationship, I'm using dataloader and projection to just fetch selected fields for child items. It work as expected, for example: load products by branch.
...
2
votes
0
answers
25
views
Power BI Many to Many relationship with vessels issue
I have a table which has VesselPositions for every insured ship. Everyday new data is added for the vessel.
In that Table I have a column named: IMO, Longitutude, Latitude, VesselPositionDate.
I also ...
0
votes
1
answer
36
views
@ManyToMany Batch Select and Insert when doing insert operation
I have a User and Role class. The User can be in Many roles and a Role can be common for Many Users thus a @ManyToMany unidirectional association.
@Entity
@Table(name = "users")
@...
2
votes
2
answers
216
views
How to automatically update extra column in sqlalchemy association table?
I have a postgresql database setup with sqlalchemy, joined table inheritance and a many-to-many association table with an extra column position, i.e. assessments and tasks are related via the ...
1
vote
1
answer
44
views
Getting list of distinct ManyToManyField objects
Given these models:
class Format(models.Model):
name = models.CharField(unique=True)
# More fields...
class Release(models.Model):
formats = models.ManyToManyField(Format, blank=True)
...