Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is a "database entity" and what types of DBMS items are considered entities? [closed]

Is it things like tables? Or would it also include things like constraints, stored procedures, packages, etc.?

I've looked around the internet, but finding elementary answers to elementary questions is sometimes a little difficult.

like image 396
IAmAN00B Avatar asked Aug 19 '09 14:08

IAmAN00B


People also ask

What is a database entity?

2) In relation to a database , an entity is a single person, place, or thing about which data can be stored. 3) In data modeling (a first step in the creation of a database), an entity is some unit of data that can be classified and have stated relationships to other entities.

What is entity and types of entity in DBMS?

Entity. A single unique object in the real world that is being mastered. Examples of an entity are a single person, single product, or single organization. Entity type. A person, organization, object type, or concept about which information is stored.

What is an entity according to DBMS?

Overview. An entity in DBMS (Database management System) is a real-world thing or a real-world object which is distinguishable from other objects in the real world. For example, a car is an entity. An attribute of an entity gives us information about the characteristic features of an entity.

What is an entity in database quizlet?

Entity. An entity is anything (a person, a place, a thing, or an event) about which data are to be collected and stored. An entity represents a particular type of object in the real world.


3 Answers

That's quite a general question!

Basically, all types that the database system itself offers, like NUMERIC, VARCHAR etc., or that the programming language of choice offers (int, string etc.) would be considered "atomic" data(base) types.

Anything that you - based on your program's or business' requirements - build from that, business objects and so forth, are entities.

Tables, constraints and so forth are database-internal objects needed to store and retrieve data, but those are general not considered "entities". The data stored in your tables, when retrieved and converted into an object, that then is an entity.

Marc

like image 166
marc_s Avatar answered Oct 04 '22 02:10

marc_s


In the entity relationship world an entity is something that may exist independently and so there is often a one-to-one relationship between entities and database tables. However, this mapping is an implementation decision: For example, an ER diagram may contain three entities: Triangle, Square and Circle and these could potentially be modelled as a single table: Shape.

Also note that some database tables may represent relationships between entities.

like image 35
Adamski Avatar answered Oct 04 '22 00:10

Adamski


This seems helpful: http://en.wikipedia.org/wiki/Entity-relationship_model

In a database an entity is a table. The table represents whatever real world concept you are trying to model (person, transaction, event).

Contraints can represents relationships between entities. These would be foreign keys. They also enforce rules like first_name can not be blank (null). A transaction must have 1 or more items. An event must have a date time.

Stored Procedures / Packages / Triggers could handle more complex relationships and/or they can handle business rules, just depends on what it's doing.

like image 39
David Avatar answered Oct 04 '22 00:10

David