week 5

3.5 Data formats

3.5.1 Know the definition of common data formats and understand their purpose and when each is used

In digital systems, data must be stored, exchanged, and interpreted in ways that both humans and machines can understand. To achieve this, information is organised using data formats. A data format defines how data is represented, encoded, and structured. Some formats focus on being lightweight and easy to parse by machines, while others are more human-readable or better suited for specific applications.

Choosing the correct data format is essential: it affects compatibility, performance, storage requirements, and security. For example, structured formats like JSON and XML are ideal for web communication, while simple formats like CSV or text files are better for raw storage or simple data transfer. Encodings like UTF-8 and ASCII ensure that text is represented consistently across devices and platforms.

Definitions, Purposes, and Uses

1. JSON (JavaScript Object Notation)

  • Definition: A lightweight text-based format for representing structured data using key–value pairs and arrays.

  • Purpose & Use: Commonly used for web APIs, configuration files, and data interchange between client and server. Easy to read by humans and parse by machines.

  • Examples: A user profile in JSON might look like:

    
     
    { "name": "Alex", "age": 22, "role": "student" }

     

  • Compatible Software: Web browsers, Python (via json library), JavaScript, Node.js, MongoDB, Postman.


2. Text File (.txt)

  • Definition: A file containing unformatted plain text, typically encoded in ASCII or UTF-8.

  • Purpose & Use: Used for notes, documentation, log files, or lightweight storage where structure isn’t required.

  • Examples: A .txt file storing error logs from a program.

  • Compatible Software: Notepad, WordPad, VS Code, Notepad++, Linux nano/vim.


3. CSV (Comma-Separated Values)

  • Definition: A plain text format where rows represent records and columns are separated by commas (or semicolons).

  • Purpose & Use: Ideal for tabular data (spreadsheets, databases) and for exporting/importing between systems.

  • Examples:

    
     

    Name, Age, Department John, 25, IT Sarah, 30, HR

  • Compatible Software: Microsoft Excel, Google Sheets, LibreOffice Calc, Python (Pandas library), SQL import/export tools.


4. UTF-8 (Unicode Transformation Format – 8-bit)

  • Definition: A character encoding capable of representing every character in the Unicode standard using 1–4 bytes.

  • Purpose & Use: Global standard for web and modern applications; supports multiple languages and symbols.

  • Examples: A UTF-8 file can contain English, Arabic, Chinese, and emojis in the same document.

  • Compatible Software: Modern browsers, Linux/Windows/Mac OS systems, text editors (VS Code, Sublime), databases (MySQL, PostgreSQL).


5. ASCII (American Standard Code for Information Interchange)

  • Definition: An older encoding system representing characters using 7-bit binary (128 possible characters).

  • Purpose & Use: Used for basic text files, programming, and communication protocols where extended character sets are unnecessary.

  • Examples: ASCII encodes ‘A’ as 65.

  • Compatible Software: Legacy systems, early internet protocols (SMTP, FTP), C/C++ compilers, terminal applications.


6. XML (eXtensible Markup Language)

  • Definition: A markup language that uses custom tags to define and store structured data in a hierarchical tree format.

  • Purpose & Use: Common for configuration files, data interchange, and web services (SOAP, RSS feeds). More verbose than JSON but supports complex structures.

  • Examples:

    
     
     Alex 22 student 

     

  • Compatible Software: Web browsers, Microsoft Excel (XML data maps), Apache web services, Java DOM parsers, .NET applications.

 

3.5.2 Understand the interrelationships between data format and data

transformation, and make judgements about the suitability of using

data formats in digital support and security.


Last Updated
2025-09-23 10:37:03

English and Maths

English


Maths


Stretch and Challenge

Stretch and Challenge


  • Fast to implement
  • Accessible by default
  • No dependencies
Homework

Homework


Equality and Diversity Calendar
How to's

How 2's Coverage




Links to Learning Outcomes

Links to Assessment criteria

 


Files that support this week


| | | | |
Week 4
Prev
Week 5
Prev
Week 6
Prev

Next