# Chapter 20 Using MySQL as a Document Store

**Table of Contents**

[20.1 Interfaces to a MySQL Document Store](document-store-interfaces.html)
[20.2 Document Store Concepts](document-store-concepts.html)
[20.3 JavaScript Quick-Start Guide: MySQL Shell for Document Store](mysql-shell-tutorial-javascript.html)
[20.3.1 MySQL Shell](mysql-shell-tutorial-javascript-shell.html)
[20.3.2 Download and Import world\_x Database](mysql-shell-tutorial-javascript-download.html)
[20.3.3 Documents and Collections](mysql-shell-tutorial-javascript-documents-collections.html)
[20.3.4 Relational Tables](mysql-shell-tutorial-javascript-relational-tables.html)
[20.3.5 Documents in Tables](mysql-shell-tutorial-javascript-documents-in-tables.html)
[20.4 Python Quick-Start Guide: MySQL Shell for Document Store](mysql-shell-tutorial-python.html)
[20.4.1 MySQL Shell](mysql-shell-tutorial-python-shell.html)
[20.4.2 Download and Import world\_x Database](mysql-shell-tutorial-python-download.html)
[20.4.3 Documents and Collections](mysql-shell-tutorial-python-documents-collections.html)
[20.4.4 Relational Tables](mysql-shell-tutorial-python-relational-tables.html)
[20.4.5 Documents in Tables](mysql-shell-tutorial-python-documents-in-tables.html)
[20.5 X Plugin](x-plugin.html)
[20.5.1 Checking X Plugin Installation](x-plugin-checking-installation.html)
[20.5.2 Disabling X Plugin](x-plugin-disabling.html)
[20.5.3 Using Encrypted Connections with X Plugin](x-plugin-encrypted-connections.html)
[20.5.4 Using X Plugin with the Caching SHA-2 Authentication Plugin](x-plugin-sha2-cache-plugin.html)
[20.5.5 Connection Compression with X Plugin](x-plugin-connection-compression.html)
[20.5.6 X Plugin Options and Variables](x-plugin-options-variables.html)
[20.5.7 Monitoring X Plugin](x-plugin-system-monitoring.html)

[]()[]()[]()

 This chapter introduces an alternative way of working with MySQL as a document store, sometimes referred to as “using NoSQL”. If your intention is to use MySQL in a traditional (SQL) way, this chapter is probably not relevant to you.

 Traditionally, relational databases such as MySQL have usually required a schema to be defined before documents can be stored. The features described in this section enable you to use MySQL as a document store, which is a schema-less, and therefore schema-flexible, storage system for documents. For example, when you create documents describing products, you do not need to know and define all possible attributes of any products before storing and operating with the documents. This differs from working with a relational database and storing products in a table, when all columns of the table must be known and defined before adding any products to the database. The features described in this chapter enable you to choose how you configure MySQL, using only the document store model, or combining the flexibility of the document store model with the power of the relational model.

 To use MySQL as a document store, you use the following server features:

* X Plugin enables MySQL Server to communicate with clients using X Protocol, which is a prerequisite for using MySQL as a document store. X Plugin is enabled by default in MySQL Server as of MySQL 8.0. For instructions to verify X Plugin installation and to configure and monitor X Plugin, see [Section 20.5, “X Plugin”](x-plugin.html).

* X Protocol supports both CRUD and SQL operations, authentication via SASL, allows streaming (pipelining) of commands and is extensible on the protocol and the message layer. Clients compatible with X Protocol include MySQL Shell and MySQL 8.0 Connectors.

* Clients that communicate with a MySQL Server using X Protocol can use X DevAPI to develop applications. X DevAPI offers a modern programming interface with a simple yet powerful design which provides support for established industry standard concepts. This chapter explains how to get started using either the JavaScript or Python implementation of X DevAPI in MySQL Shell as a client. See [X DevAPI User Guide](https://dev.mysql.com/doc/x-devapi-userguide/en/) for in-depth tutorials on using X DevAPI.

