Prepstellar

DP-900 · Data Representation

22 cards

Data Representation Types

Swipe, scroll or use ← →
  1. Facts, entities, and attributes

    Data is a collection of facts — numbers, descriptions, and observations that record information. On its own a fact is inert; it becomes useful once it is organized.

    Data structures usually organize facts around entities, the things an organization cares about: customers, products, sales orders. An entity typically has one or more attributes that describe it. A customer's name, address, and phone number are attributes of that customer.

    Everything in this concept turns on one question: how consistently do the instances of an entity organize those attributes? Answer that and you have the representation type. The subject of the data — customers, products, anything — does not decide it.

    1 / 22
  2. Quick check

    What decides which representation type a set of data belongs to?

    1. AHow consistently each instance organizes its attributes

      Right. The representation type follows from how each instance is organized: the same fields for all, some variation, or no specific structure at all.

    2. BWhether the data describes customers, products, or orders

      The kind of entity is the subject of the data, and the same subject can be represented under different structural rules.

    3. CWhether the facts are numbers, descriptions, or observations

      Facts of every kind appear in all three representation types, so the type of fact settles nothing.

    2 / 22

  3. Structured data has a fixed schema

    Structured data adheres to a fixed schema. That single sentence contains the whole test: because the schema is fixed, every instance has the same fields or properties. No instance can quietly add one, and none can leave one out of the definition.

    Its most common schema is tabular. Data is arranged in a table, and the table is what most people picture when they hear "structured".

    Structured data is often stored in a database. In a relational model, multiple tables can reference one another through key values — a sales order table can point at the customer table instead of repeating the customer's details in every row.

    Those keys are a convenience of the model, not a loosening of it. The defining feature for classification remains the fixed schema shared by all instances.

    3 / 22
  4. Structured data has a fixed schema

    A worked example makes the rule concrete. A customer table places one customer in each row and keeps attributes such as name and address in columns.

    CustomerID Name Address Phone
    1001 A. Ferrer 12 Main St 555-0101
    1002 B. Okafor 8 Park Ave 555-0177
    1003 C. Lindqvist 40 Hill Rd 555-0142

    Every row carries the same four attributes. If one customer had no phone number, the column would still exist for that row — the schema does not change to suit an instance. That is exactly what stops being true when data is semi-structured.

    4 / 22
  5. Quick check

    What must be true of every instance in a structured dataset?

    1. AInstances keep some overall organization but may carry different fields

      That describes semi-structured data, where an overall organization survives but the specific fields vary.

    2. BEvery instance follows the same fixed schema of fields or properties

      Right. Structured data adheres to a fixed schema, so every instance has the same fields or properties.

    3. CEach instance may change both its organization and its properties

      Data free to change its organization from instance to instance has no fixed schema and is not structured.

    5 / 22

  6. Read the tabular schema correctly

    In a table, the two axes have fixed meanings, and swapping them is a common slip.

    Axis What it represents Customer table example
    Row One instance of an entity One individual customer
    Column One attribute of the entity Name, address, phone

    So a row is a whole customer and a column is one property shared by all of them. Rows do not hold attributes, columns do not hold separate data stores, and neither axis holds a schema or an unrelated binary file.

    Key values are the third element: they reference an instance in another table so that related tables can be joined. A key value is a link to an entity, not an entire table folded into a column.

    6 / 22
  7. Quick check

    In the most common tabular schema for structured data, what do rows and columns represent?

    1. ARows represent schemas, and columns represent unrelated binary files

      A row holds one instance rather than a schema, and a column holds an attribute rather than a binary file.

    2. BRows represent key values, and columns represent complete entity tables

      A key value links to an instance in another table; it is not what a row stands for, and a column is not a whole table.

    3. CRows represent entity instances, and columns represent the entity's attributes

      Right. Each row represents one instance of an entity, while columns represent the entity's attributes.

    7 / 22

  8. Keep your progress in the app

    That’s 3 of 9 quick checks. In the app they stay answered, and every lesson remembers where you left off.

  9. Semi-structured data permits variation

    Semi-structured data has some structure but permits variation between entity instances. Both halves matter. There is a recognizable organization — the instances are clearly the same kind of thing — and yet instances need not carry exactly the same fields.

    The classic illustration is contact details. Most customers might have one email address, another customer might have several, and another might have none at all.

    A fixed schema cannot express that without waste or loss: it would need an Email2 and Email3 column that stay empty for nearly everyone. A semi-structured representation simply lets one record carry more email entries than another while both remain customer records.

    8 / 22
  10. Semi-structured data permits variation

    So the difference from structured data is not the absence of organization. It is where the organization stops.

    Aspect Structured Semi-structured
    Overall organization Present and fixed Present
    Fields per instance Identical for all instances May differ between instances
    Number of values in an attribute Fixed by the schema May differ between instances
    Typical shape Rows and columns Documents or records

    Read the middle two rows as the test. If instances share an organization but may omit or repeat selected fields, the data is semi-structured.

    9 / 22
  11. Quick check

    Customer records share an overall organization, but some have several email addresses and others have none. Which representation type fits?

    1. AStructured data, with one fixed schema and identical properties everywhere

      A fixed schema requires the same fields or properties in every instance, which these records do not have.

    2. BSemi-structured data, with variation permitted between instances

      Right. Semi-structured data has some structure but permits variation between entity instances, which is exactly what the differing email counts show.

    3. CUnstructured data, with no recurring organization at all

      The records do share a recognizable organization as customer records, so they are not without structure.

    10 / 22

  12. JSON is the common semi-structured format

    JavaScript Object Notation, or JSON, is a common format for semi-structured data. It stores records as documents rather than rows, so each document carries its own field names.

    JSON customer documents can all contain address and contact information while their specific fields differ. One address can include a unit field while another does not. One contact collection can contain both phone and email entries while another contains only an email.

    { "name": "A. Ferrer",
      "address": { "street": "12 Main St", "unit": "4B" },
      "contact": [ { "phone": "555-0101" }, { "email": "af@example.com" } ] }
    
    { "name": "B. Okafor",
      "address": { "street": "8 Park Ave" },
      "contact": [ { "email": "bo@example.com" } ] }
    

    Both are recognizably customer documents; neither could sit in the other's fixed schema without change. That combination of recognizable organization and instance-level variation is the central semi-structured pattern.

    11 / 22
  13. Quick check

    Two JSON customer documents both contain address and contact sections, but their specific fields differ. How should this be classified?

    1. ASemi-structured, because there is organization while the fields are free to vary

      Right. The shared address and contact organization plus the differing fields is precisely the semi-structured pattern, and JSON is a common format for it.

    2. BStructured, because the JSON format requires identical properties in every document

      JSON imposes no such requirement; documents of the same kind can and do carry different fields.

    3. CUnstructured, because JSON documents cannot carry recognizable organization

      The shared address and contact sections are recognizable organization, so the documents are not unstructured.

    12 / 22

  14. Unstructured data has no specific structure

    Unstructured data does not have a specific structure. Documents, images, audio, video, and binary files can all belong to this category.

    Unlike a fixed-schema table, their contents are not organized as the same fields or properties for every entity instance. A photograph has no Name column; an audio recording has no row. Whatever internal format the file uses, it does not present recurring attributes that could be compared across instances.

    The absence of a specific structure is the deciding feature — not the file size, not the medium, not whether an application can open it. A collection made of native images, audio recordings, videos, and application-specific binary documents is therefore an unstructured collection.

    13 / 22
  15. Unstructured data has no specific structure

    Setting the extremes side by side sharpens the contrast.

    Native media and binary documents Fixed-schema customer table
    Shared fields None; the files can lack a specific structure Every instance carries the same fields
    Comparable instances Not as recurring attributes Row by row, column by column
    Classification Unstructured Structured

    The trap is to invert one half of that table. Media files do not require identical attribute columns, and a fixed-schema table is not free to omit a field for one instance. Each side is defined by exactly what the other lacks.

    14 / 22
  16. Quick check

    An archive must retain native images, audio recordings, videos, and application-specific binary documents, none of which share a schema of recurring fields. Which classification fits?

    1. AStructured, because every binary file follows one common table schema

      Binary media files do not follow a table schema, and a structured classification requires the same fields in every instance.

    2. BSemi-structured, because media files carry varying address sections

      Address sections belong to the semi-structured document example, not to images, audio, or video files.

    3. CUnstructured, because the native files share no specific structure

      Right. Unstructured data does not have a specific structure, and documents, images, audio, video, and binary files belong to that category.

    15 / 22

  17. Turn a structured set into a semi-structured one

    It helps to see the boundary as a change rather than a label. Start from records that all share one fixed schema, and ask what single change would make them semi-structured.

    The answer is variation between instances while the organization survives: allowing individual records to omit or repeat selected fields. As soon as one record can carry two email entries and another none, the fixed schema is gone and the recognizable organization is not.

    Two changes that do not do it are worth naming. Keeping identical fields for every record leaves the data structured, and so does putting every instance in a row with attributes in fixed columns — that is the tabular form of the same rule. Replacing the records with native media files overshoots the boundary entirely and lands on unstructured.

    16 / 22
  18. Quick check

    Which change introduces the defining semi-structured feature into records that previously shared one fixed schema?

    1. AAllowing individual records to omit or repeat selected fields while keeping the organization

      Right. Semi-structured data keeps some structure but permits variation between entity instances, such as an attribute holding several values in one record and none in another.

    2. BKeeping identical fields in every record and continuing to use the same schema

      Identical fields in every record is the definition of a fixed schema, so the data stays structured.

    3. CReplacing the records with native media files that have no organization

      Removing the organization altogether produces unstructured data rather than the semi-structured middle ground.

    17 / 22

  19. Classify by the shape, not by the subject

    Do not classify a representation merely because it contains customer or product information. The same kind of entity can be represented under different structural rules, and the classification follows the rules.

    Inspect how each instance is organized and choose accordingly:

    • Structured when all instances follow the same fields or properties, commonly as rows and columns.
    • Semi-structured when instances retain some organization but differ in their specific fields, or in how many values an attribute holds.
    • Unstructured when the data has no specific structure, as with documents, images, audio, video, and binary files.
    18 / 22
  20. Classify by the shape, not by the subject

    Two scenarios show the rule doing real work.

    A sales system requires every product instance to have the same properties, places each product in one row with each attribute in a column, and uses key values to reference related tables. Same properties for every instance plus rows and columns: this is structured, and the related tables change nothing — keys link instances, they do not let fields vary.

    A customer export preserves address and contact sections, but some addresses include a unit field and some contact collections hold one email while others hold both phone and email. Organization survives, fields and value counts vary: this is semi-structured. One optional field does not remove all organization, and shared sections do not guarantee identical fields.

    19 / 22
  21. Quick check

    A sales system requires every product instance to have the same properties, puts each product in a row with attributes in columns, and uses key values to reference related tables. Which classification fits?

    1. ASemi-structured, because related tables let each product use different fields

      Key references link instances across tables; they do not permit an instance to carry a different set of fields.

    2. BStructured, because all instances share one fixed tabular schema

      Right. Every instance has the same properties in a table of rows and columns, which is a fixed schema and therefore structured data.

    3. CUnstructured, because key references remove any specific structure

      Keys are part of a relational design, and the data described has a very specific structure indeed.

    20 / 22

  22. Key takeaways

    • Structured data uses a fixed schema, so every instance carries the same fields or properties — most commonly as a table with rows for entity instances and columns for attributes.
    • Semi-structured data keeps some organization while letting fields vary between instances, including how many values an attribute holds; JSON is the common format for it.
    • Unstructured data has no specific structure, and includes documents, images, audio, video, and binary files.
    • Classify by inspecting the instances, not by the entity the data happens to describe. Customers can be represented all three ways.
    21 / 22
  23. Quick check

    Which line correctly pairs each representation type with its defining rule?

    1. AStructured varies by instance, semi-structured has no structure, unstructured uses a fixed schema

      Every pairing here is displaced by one: a fixed schema belongs to structured data, not to unstructured files.

    2. BStructured has no structure, semi-structured uses rows and columns, unstructured varies by instance

      Rows and columns are the common tabular form of structured data, and structured data is defined by having a fixed schema.

    3. CStructured uses a fixed schema, semi-structured varies by instance, unstructured has no specific structure

      Right. A fixed schema for all instances, organization with permitted variation, and no specific structure are the three defining rules in order.

    22 / 22

  24. 9 quick checks · then the test

    In the app, finishing the quick checks opens this lesson’s 10-question test, and the ones you miss come back exactly when you’re about to forget them.

The whole course, on your phone

Lessons you can read, audio you can listen to on the way to work, and practice that remembers what you got wrong.