entity Questions

3

Solved

Just starting with Domain Driven Design and I've learned that you should keep your model in a valid state and when creating a new instance of a class it's recomended to put all required attributes ...
Salto asked 16/12, 2015 at 15:15

2

Solved

I'm using Entity Framework 5 and have a generic repository, within which are several methods like the two Get() methods below: public TEntity GetById(int id) { return DbSet.Find(id); } public TE...
Demote asked 15/1, 2013 at 19:39

7

I have a tree structure in the DB with TreeNodes table. the table has nodeId, parentId and parameterId. in the EF, The structure is like TreeNode.Children where each child is a TreeNode... I also h...
Reorder asked 15/2, 2010 at 14:17

10

Solved

What's the HTML character entity for the # sign? I've looked around for "pound" (which keeps returning the currency), and "hash" and "number", but what I try doesn't s...
Hooknosed asked 11/6, 2010 at 18:14

14

It seems to me that I have to retrieve an object before I delete it with entity framework like below var customer = context.Customers.First(c => c.Id == 1); context.DeleteObject(customer); co...
Carbide asked 18/3, 2010 at 16:11

3

Solved

Is there a way to find out the java.lang.Class that is the one having @Entity(name = "X")? In other words use the Entity Name to get the classname of the Entity, of course at runtime :)
Unclose asked 2/10, 2015 at 15:44

35

Solved

I receive following error when I save the object using Hibernate object references an unsaved transient instance - save the transient instance before flushing
Marney asked 20/2, 2010 at 16:17

3

When I use: php bin/console make:entity to create a new db entity, I get the following error: In DoctrineHelper.php line 180: Class "Doctrine\Persistence\Mapping\Driver\AnnotationDriver" ...
Douzepers asked 14/5, 2022 at 14:51

4

Solved

I am studying JPA in Spring application and I have some doubts related to the @Entity annotation. So I have a model class like this: @Entity @Table(name= “T_CUSTOMER”) public class Customer { @...
Phobia asked 29/3, 2015 at 18:13

9

Solved

I have a model class that is mapped to a postgres database using hibernate. My model class is: @Entity @Table(name="USER") public class User { @Id @GeneratedValue @Column(name="id") private ...
Pistole asked 20/8, 2017 at 12:49

5

Solved

I am trying to use reflection to make a dynamic select through Entity Framework. The idea is that the method will get as parameters the column name, the value for each column to search and the ord...
Palliasse asked 18/7, 2014 at 4:33

2

Solved

I have a list of objects Human. I need to get a list of its id. I do that. Can i do it more simplier? It looks not so good val idsList = ArrayList<Int>() humansList.forEach{idsList.add(it.id...
Robby asked 8/6, 2021 at 6:57

6

Solved

I am seeking clarification on the definitions of the terms Entity, Model, DataModel, and ViewModel within the context of software development. Could someone provide a detailed explanation for...
Laconic asked 5/1, 2012 at 14:20

2

I am doing a lot of research and experiment to use an enum array in my entity. import { Program } from '../../program/entities/program.entity' import { Column, Entity, JoinTable, ManyToMany, M...
Pretorius asked 22/9, 2021 at 5:36

6

Solved

Is it possible to determine the native table name of an entity? If a Table annotation is present it's easy: entityClass.getAnnotation(Table.class).name() But what about if no Table annotation i...
Thinia asked 26/2, 2010 at 13:57

9

Solved

I have a JPA entity already persisted in the database. I would like to have a copy of it (with a different id), with some fields modified. What is the easiest way to do this? Like: setting it's ...
Melicent asked 24/7, 2012 at 6:11

2

Solved

This question is in relation to a Plugin which I am now creating for Dynamics CRM 2011. I have an entity which has 5 attributes. 1 of these attributes is a Lookup to another entity. What I am try...
Scholarship asked 17/3, 2011 at 11:58

9

Solved

I just declared an entity called "Users" array: var UsersArray = [Users]() I got this error: use of unresolved identifiers "Users" hint : I did import CoreData and created the entity
Rudiment asked 31/10, 2019 at 22:21

5

Solved

Let's say I have a User Entity : $user = new User(007); echo $user->getName(); // display Bond echo $user->getGender(); // display "Male"; echo $user->getDesignation() // display "Monsieu...
Ashbaugh asked 23/11, 2011 at 14:53

7

Solved

I try to read C# ECMA to find out what an entity is but failed. Is this a instance of class? Or types+members? Or any single word in the code that shows no red wavy line under it?
Kokand asked 3/1, 2018 at 9:9

4

Solved

at present, I have: string outputRow = string.Empty; foreach (var entityObject in entityObjects) { outputRow = entityObject.field1 + "," + entityObject.Field2 etc.... } I'm still new to the...
Karaite asked 7/7, 2010 at 23:9

1

Solved

So I asked a different question before, and arrived at a partial solution. I was able to add gestures to ONE of the two model entities on one scene, but not the other. Because when you print the sc...

7

Solved

I just started on a project converting an application from raw ADO.NET and embedded SQL to Entity. I ran in to a problem with one of the views used by the application. The view has no primary key a...
Penetralia asked 6/7, 2012 at 22:2

24

Solved

I have a JPA-persisted object model that contains a many-to-one relationship: an Account has many Transactions. A Transaction has one Account. Here's a snippet of the code: @Entity public class T...
Rovner asked 13/11, 2012 at 22:45

2

Solved

Here I came up with the first approach: that is, using foreach clause on DataSet to get the items and fill in your Entity. But this method can't be reused when the something changes. So I think ma...
Jochbed asked 10/10, 2013 at 2:50

© 2022 - 2024 — McMap. All rights reserved.