SlideShare a Scribd company logo
1 / 100
2 / 1002 / 100
 
Safe Harbor Statement
The following is intended to outline our general product direction. It is intended for
information purpose only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied up in
making purchasing decisions. The development, release and timing of any features or
functionality described for Oracle´s product remains at the sole discretion of Oracle.
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
3 / 100
about me - http://about.me/lefred
Who am I ?
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
4 / 100
Frédéric Descamps
@lefred
MySQL Evangelist
Hacking MySQL since 3.23
devops believer
living in Belgium 🇧🇪
http://lefred.be
 
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
5 / 100
MySQL
a Document Store with all the benefits of a RDBMS
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
6 / 100
Why ?
Developers don´t really like SQL
 
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
7 / 100
Why ?
SQL can be complicated and slows down the initial development
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
8 / 100
easy operations
What do developers want ?
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
9 / 100
Use Objects / Documents
Developers want just to use objects
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
10 / 100
Use Objects / Documents
Developers want just to use objects
that´s why they usually love what DBAs hate the most ORMs !).
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
11 / 100
Use Objects / Documents
Developers want just to use objects
that´s why they usually love what DBAs hate the most ORMs !).
They want to deal with these objects easily (CRUD operations) and they don´t want to
think about schema design (slows down the initial development process).
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
12 / 100
Use Objects / Documents
Developers want just to use objects
that´s why they usually love what DBAs hate the most ORMs !).
They want to deal with these objects easily (CRUD operations) and they don´t want to
think about schema design (slows down the initial development process).
But they also want to keep their data safe and use transactions.
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
13 / 100
RDBMS & MySQL
Relational Databases
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
14 / 100
Relational Databases
Data Integrity
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
15 / 100
Relational Databases
Data Integrity
normalization
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
16 / 100
Relational Databases
Data Integrity
normalization
constraints (foreign keys, ...)
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
17 / 100
Relational Databases
Data Integrity
normalization
constraints (foreign keys, ...)
Atomicity, Consistency, Isolation, Durability
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
18 / 100
Relational Databases
Data Integrity
normalization
constraints (foreign keys, ...)
Atomicity, Consistency, Isolation, Durability
ACID compliant
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
19 / 100
Relational Databases
Data Integrity
normalization
constraints (foreign keys, ...)
Atomicity, Consistency, Isolation, Durability
ACID compliant
transactions
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
20 / 100
Relational Databases
Data Integrity
normalization
constraints (foreign keys, ...)
Atomicity, Consistency, Isolation, Durability
ACID compliant
transactions
SQL
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
21 / 100
Relational Databases
Data Integrity
normalization
constraints (foreign keys, ...)
Atomicity, Consistency, Isolation, Durability
ACID compliant
transactions
SQL
powerfull query language
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
22 / 100
NoSQL & MySQL
NoSQL Databases
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
23 / 100
NoSQL or Document Store
Schemaless
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
24 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
25 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
26 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
27 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
embedded arrays or objects
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
28 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
embedded arrays or objects
valid solution when natural data can´t be modelized optimaly into a relational
model
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
29 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
embedded arrays or objects
valid solution when natural data can´t be modelized optimaly into a relational
model
objects persistance without the use of any ORM - mapping oobject-oriented
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
30 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
embedded arrays or objects
valid solution when natural data can´t be modelized optimaly into a relational
model
objects persistance without the use of any ORM - mapping oobject-oriented
JSON
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
31 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
embedded arrays or objects
valid solution when natural data can´t be modelized optimaly into a relational
model
objects persistance without the use of any ORM - mapping oobject-oriented
JSON
close to frontend
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
32 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
embedded arrays or objects
valid solution when natural data can´t be modelized optimaly into a relational
model
objects persistance without the use of any ORM - mapping oobject-oriented
JSON
close to frontend
native in JS
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
33 / 100
NoSQL or Document Store
Schemaless
no schema design, no normalization, no foreign keys, no data types, ...
very quick initial development
Flexible data structure
embedded arrays or objects
valid solution when natural data can´t be modelized optimaly into a relational
model
objects persistance without the use of any ORM - mapping oobject-oriented
JSON
close to frontend
native in JS
easy to learn
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
34 / 100
How DBAs see data
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
35 / 100
How DBAs see data How Developers see data
{
"GNP" : 249704,
"Name" : "Belgium",
"government" : {
"GovernmentForm" :
"Constitutional Monarchy, Federation",
"HeadOfState" : "Philippe I"
},
"_id" : "BEL",
"IndepYear" : 1830,
"demographics" : {
"Population" : 10239000,
"LifeExpectancy" : 77.8000030517578
},
"geography" : {
"Region" : "Western Europe",
"SurfaceArea" : 30518,
"Continent" : "Europe"
}
}
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
36 / 100
What if there was a way to provide both SQL
and NoSQL on one stable platform that has
proven stability on well know technology with
a large Community and a diverse ecosystem ?
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
37 / 100
DBMS or NoSQL ?
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
38 / 100
DBMS or NoSQL ?
Why not both ?
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
39 / 100
The MySQL Document Store !
SQL is now optional ?!
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
40 / 100
SQL is now optional ?!
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
41 / 100
Developers:
[x] schemaless
[x] rapid prototying/simpler APIs
[x] document model
[x] transactions
Operations:
[x] performance
management/visibility
[x] robust replication, backup,
restore
[x] comprehensive tooling
ecosystem
[x] simpler application schema
upgrades
Business Owner:
[x] don't lose my data == ACID trx
[x] capture all my data =
extensible/schemaless
[x] product on schedule/time to
market = rapid developement
A solution for all
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
42 / 100
MySQL Document Store
the Solution
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
43 / 100
Built on
the MySQL
JSON Data
type and
Proven
MySQL
Server
Technology
Provides a schema flexible JSON Document Store
No SQL required
No need to define all possible attributes, tables, etc.
Uses new X DevAPI
Can leverage generated column to extract JSON values
into materialized columns that can be indexed for fast
SQL searches.
Document can be ~1GB
It's a column in a row of a table
It cannot exceed max_allowed_packet
Allows use of modern programming styles
No more embedded strings of SQL in your code
Easy to read
Also works with relational Tables
Proven MySQL Technology
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
44 / 100
X Protocol Connectors
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
45 / 100
X DevAPI We provide connectors for
C++, Java, .Net, Node.js, Python, PHP
working with Communities to help them supporting
it too
New MySQL Shell
Command Completion
Python, JavaScrips & SQL modes
Admin functions
New Util object
A new high-level session concept that can scale from
single MySQL Server to a multiple server environment
Non-blocking, asynchronous calls follow common
language patterns
Supports CRUD operations
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
46 / 100
PY
JS
SQL
>
MySQL 8.0
Upgrade Checker
Auto Completion
&
Command History
Output
Formats
(table, json, tabs)
Prompt
Themes
Batch
Execution
5.7
8.0
JS
Document
Store
X dev API
SQL CLI InnoDB
Cluster
importJSON
JSJS
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
47 / 100
Migration from MongoDB to MySQL DS
For this example, I will use the well known restaurants collection:
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
48 / 100
Migration from MongoDB to MySQL DS
For this example, I will use the well known restaurants collection:
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
49 / 100
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
50 / 100
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
51 / 100
Let´s query
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
52 / 100
Let´s query
That´s too much records to show it here... let´s limit it
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
53 / 100
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
54 / 100
Some more examples
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
55 / 100
Some more examples
Let´s add a selection criteria:
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
56 / 100
Using IN...
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
57 / 100
Syntax slightly different than MongoDB
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
58 / 100
Syntax slightly different than MongoDB
> db.restaurants. nd({"cuisine": "French",
"borough": { $not: /^Manhattan/} },
{"_id":0, "name": 1,"cuisine": 1, "borough": 1}).limit(2)
{ "borough" : "Queens", "cuisine" : "French",
"name" : "La Baraka Restaurant" }
{ "borough" : "Queens", "cuisine" : "French",
"name" : "Air France Lounge" }
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
59 / 100
And for developers ?
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
60 / 100
And for developers ?
$session = mysql_xdevapigetSession("mysqlx://fred:MyP@ssw0rd%@localhost");
$schema = $session->getSchema("docstore");
$collection = $schema->getCollection("restaurants");
$results = $collection-> nd($search)->execute()->fetchAll();
...
foreach ($results as $doc) {
echo "<tr><td><a href='?id=${doc[_id]}'>${doc[name]}</a></td>";
echo "<td>${doc[borough]}</td><td>${doc[cuisine]}</td></tr>";
}
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
61 / 100
And for developers ?
$session = mysql_xdevapigetSession("mysqlx://fred:MyP@ssw0rd%@localhost");
$schema = $session->getSchema("docstore");
$collection = $schema->getCollection("restaurants");
$results = $collection-> nd($search)->execute()->fetchAll();
...
foreach ($results as $doc) {
echo "<tr><td><a href='?id=${doc[_id]}'>${doc[name]}</a></td>";
echo "<td>${doc[borough]}</td><td>${doc[cuisine]}</td></tr>";
}
 
Easy, using only CRUD operations !
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
62 / 100
CRUD operations
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
63 / 100
CRUD operations for collections
Add a document
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
64 / 100
CRUD operations for collections
Add a document
collection.add({ name: 'fred', age: 42 })
.add({ name: 'dave', age: 23 })
.execute()
collection.add([
{ name: 'dimo', age: 50 },
{ name: 'kenny', age: 25 }
]).execute()
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
65 / 100
CRUD operations for collections
Modify a document
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
66 / 100
CRUD operations for collections
Modify a document
collection.modify('name = :name')
.bind('name', 'fred')
.set('age', 43)
.sort('name ASC')
.limit(1)
.execute()
collection.modify('name = :name')
.bind('name', 'fred')
.patch({ age: 43, active: false })
.sort('name DESC')
.limit(1)
.execute()
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
67 / 100
CRUD operations for collections
Remove a document
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
68 / 100
CRUD operations for collections
Remove a document
collection.remove('name = :name')
.bind('name', 'fred')
.sort('age ASC')
.limit(1)
.execute()
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
69 / 100
MySQL Document Store Objects Summary
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
70 / 100
All you need to know is here:
https://dev.mysql.com/doc/x-devapi-userguide/en/crud-operations-overview.html
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
71 / 100
we do care about your data
MySQL Document Store is Full ACID Compliant
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
72 / 100
Document Store Full ACID !
It relies on the proven MySQL InnoDB´s strength & robustness:
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
73 / 100
Document Store Full ACID !
It relies on the proven MySQL InnoDB´s strength & robustness:
innodb_ ush_log_at_trx_commit = 1
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
74 / 100
Document Store Full ACID !
It relies on the proven MySQL InnoDB´s strength & robustness:
innodb_ ush_log_at_trx_commit = 1
innodb_doublewrite = ON
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
75 / 100
Document Store Full ACID !
It relies on the proven MySQL InnoDB´s strength & robustness:
innodb_ ush_log_at_trx_commit = 1
innodb_doublewrite = ON
sync_binlog = 1
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
76 / 100
Document Store Full ACID !
It relies on the proven MySQL InnoDB´s strength & robustness:
innodb_ ush_log_at_trx_commit = 1
innodb_doublewrite = ON
sync_binlog = 1
transaction_isolation = REPEATABLE-READ|READ-
COMMITTED|...
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
77 / 100
Document Store Full ACID !
It relies on the proven MySQL InnoDB´s strength & robustness:
innodb_ ush_log_at_trx_commit = 1
innodb_doublewrite = ON
sync_binlog = 1
transaction_isolation = REPEATABLE-READ|READ-
COMMITTED|...
We do care about your data !
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
78 / 100
MySQL DS Full ACID - Transactions support
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
79 / 100
MySQL DS Full ACID - Transactions support
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
80 / 100
OK we have Document Store, CRUD and ACID
but what makes MySQL Document Store unique ?
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
81 / 100
Challenge: list the best restaurant of each type
of food and show the top 10, with the best one
first !
 
don't forget that all these restaurants are just JSON documents
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
82 / 100
NoSQL as SQL - aggregation
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
83 / 100
NoSQL as SQL - aggregation
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
84 / 100
NoSQL as SQL - aggregation
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
85 / 100
NoSQL or SQL
You have the possibility to write clean and neat code:
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
86 / 100
NoSQL or SQL
You have the possibility to write clean and neat code:
$results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll();
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
87 / 100
NoSQL or SQL
You have the possibility to write clean and neat code:
$results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll();
Or use SQL only when really needed:
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
88 / 100
NoSQL or SQL
You have the possibility to write clean and neat code:
$results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll();
Or use SQL only when really needed:
$results = $session->sql('WITH cte1 AS (SELECT doc->>"$.name" AS name,
doc->>"$.cuisine" AS cuisine,
(SELECT AVG(score) FROM JSON_TABLE(doc, "$.grades[*]" COLUMNS (score INT
PATH "$.score")) AS r) AS avg_score FROM docstore.restaurants)
SELECT *, RANK()
OVER ( PARTITION BY cuisine ORDER BY avg_score) AS `rank`
FROM cte1 ORDER BY `rank`, avg_score DESC LIMIT 10;')->execute();
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
89 / 100
NoSQL or SQL
You have the possibility to write clean and neat code:
$results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll();
Or use SQL only when really needed:
$results = $session->sql('WITH cte1 AS (SELECT doc->>"$.name" AS name,
doc->>"$.cuisine" AS cuisine,
(SELECT AVG(score) FROM JSON_TABLE(doc, "$.grades[*]" COLUMNS (score INT
PATH "$.score")) AS r) AS avg_score FROM docstore.restaurants)
SELECT *, RANK()
OVER ( PARTITION BY cuisine ORDER BY avg_score) AS `rank`
FROM cte1 ORDER BY `rank`, avg_score DESC LIMIT 10;')->execute();
All in the same MySQL X Session !
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
90 / 100
MySQL Shell is for DBAs and Developers
 
 
DEMO
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
91 / 100
what do I gain ?
Conclusion
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
92 / 100
schemaless
flexible data structure
easy to start (CRUD)
Conclusion
This is the best of the two worlds in one product !
Data integrity
ACID Compliant
Transactions
SQL
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
93 / 100
94 / 100
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
95 / 100
http://lefred.be/content/top-10-reasons-for-
nosql-with-mysql/
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
96 / 100
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
97 / 100
  May 9th, 2019
Hotel NH Collection Roma
Giustiniano
Via Virgilio, 1 E/F/G, 0019
ROMA
MySQL Day Roma
You are invited to listen last news on MySQL
8.0, watch demos and be in contact with the
MySQL Italian Team!
http://bit.ly/MySQLDayRoma2019
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
98 / 100
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
99 / 100
Thank you !
Any Questions ?
share your 💕 for MySQL on social media using @mysql #MySQL8isGreat
#MySQL
Copyright @ 2019 Oracle and/or its affiliates. All rights reserved.
100 / 100

More Related Content

What's hot (20)

PDF
MySQL : State of the Dolphin May 2019
Frederic Descamps
 
PDF
OpenExpo Virtual Experience 2020: MySQL 8.0 Document Store - Discovery of a n...
Frederic Descamps
 
PPTX
PHP, The X DevAPI, and the MySQL Document Store -- Benelux PHP Confernece 2019
Dave Stokes
 
PDF
MySQL Shell - the best DBA tool ?
Frederic Descamps
 
PDF
How to operate MySQL InnoDB Cluster with MySQL Shell
Frederic Descamps
 
PDF
Python and MySQL 8.0 Document Store
Frederic Descamps
 
PDF
MySQL InnoDB Cluster - Advanced Configuration & Operations
Frederic Descamps
 
PDF
Percona Live Europe 2018 MySQL Group Replication... the magic explained
Frederic Descamps
 
PDF
MySQL Document Store - How to replace a NoSQL database by MySQL without effor...
Frederic Descamps
 
PDF
MySQL Tech Café #8: MySQL 8.0 for Python Developers
Frederic Descamps
 
PDF
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
Frederic Descamps
 
PDF
MySQL Group Replication: Handling Network Glitches - Best Practices
Frederic Descamps
 
PDF
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
Frederic Descamps
 
PDF
MySQL 8.0 : High Availability Solution for Everybody
Frederic Descamps
 
PDF
Looking Inside the MySQL 8.0 Document Store
Frederic Descamps
 
PDF
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
Frederic Descamps
 
PDF
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Frederic Descamps
 
PDF
MySQL Shell: the best DBA tool !
Frederic Descamps
 
PDF
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
Frederic Descamps
 
PDF
the State of the Dolphin - October 2020
Frederic Descamps
 
MySQL : State of the Dolphin May 2019
Frederic Descamps
 
OpenExpo Virtual Experience 2020: MySQL 8.0 Document Store - Discovery of a n...
Frederic Descamps
 
PHP, The X DevAPI, and the MySQL Document Store -- Benelux PHP Confernece 2019
Dave Stokes
 
MySQL Shell - the best DBA tool ?
Frederic Descamps
 
How to operate MySQL InnoDB Cluster with MySQL Shell
Frederic Descamps
 
Python and MySQL 8.0 Document Store
Frederic Descamps
 
MySQL InnoDB Cluster - Advanced Configuration & Operations
Frederic Descamps
 
Percona Live Europe 2018 MySQL Group Replication... the magic explained
Frederic Descamps
 
MySQL Document Store - How to replace a NoSQL database by MySQL without effor...
Frederic Descamps
 
MySQL Tech Café #8: MySQL 8.0 for Python Developers
Frederic Descamps
 
MySQL Database Service Webinar - Installing WordPress in OCI with MDS
Frederic Descamps
 
MySQL Group Replication: Handling Network Glitches - Best Practices
Frederic Descamps
 
MySQL Day Virtual: Best Practices Tips - Upgrading to MySQL 8.0
Frederic Descamps
 
MySQL 8.0 : High Availability Solution for Everybody
Frederic Descamps
 
Looking Inside the MySQL 8.0 Document Store
Frederic Descamps
 
State of the Dolphin 2020 - 25th Anniversary of MySQL with 8.0.20
Frederic Descamps
 
Oracle Open World Middle East - MySQL 8 a Giant Leap for SQL
Frederic Descamps
 
MySQL Shell: the best DBA tool !
Frederic Descamps
 
MySQL 8.0 InnoDB Cluster - Easiest Tutorial
Frederic Descamps
 
the State of the Dolphin - October 2020
Frederic Descamps
 

Similar to Oracle Code Roma: NoSQL + SQL = MySQL (20)

PDF
Oracle Open World 2018 / Code One : MySQL 8.0 Document Store
Frederic Descamps
 
PDF
pre-FOSDEM MySQL day, February 2018 - MySQL Document Store
Frederic Descamps
 
PDF
MySQL User Group NL: MySQL 8.0 Document Store- NoSQL with all the benefits of...
Frederic Descamps
 
PDF
DataOps barcelona - MySQL 8.0 document store: NoSQL with all the benefits of ...
Frederic Descamps
 
PDF
MySQL 8.0 Document Store - Discovery of a New World
Frederic Descamps
 
PDF
Oracle Code Event - MySQL JSON Document Store
Mark Swarbrick
 
PDF
Introduction to MySQL Document Store
Frederic Descamps
 
PDF
MySQL Document Store (Oracle Code Warsaw 2018)
Vittorio Cioe
 
PPTX
Big data oracle_introduccion
Fran Navarro
 
PDF
The New Database Frontier: Harnessing the Cloud
Inside Analysis
 
PDF
Oracle PL/SQL 12c and 18c New Features + RADstack + Community Sites
Steven Feuerstein
 
PDF
はじめてのOracle Cloud Infrastructure(Oracle Cloudウェビナーシリーズ: 2020年6月24日)
オラクルエンジニア通信
 
PPTX
A Step by Step Introduction to the MySQL Document Store
Dave Stokes
 
PDF
Database Basics with PHP -- Connect JS Conference October 17th, 2015
Dave Stokes
 
PDF
DOAG Big Data Days 2017 - Cloud Journey
Harald Erb
 
PDF
Why Use an Oracle Database?
Markus Michalewicz
 
PDF
Oracle NoSQL
Oracle Korea
 
PDF
MySQL 8.0 Introduction to NoSQL + SQL
Manuel Contreras
 
PDF
Joe Celko s SQL for Smarties Fourth Edition Advanced SQL Programming Joe Celko
joaraepri
 
PPTX
Oracle Database House Party_Oracle Machine Learning to Pick a Good Inexpensiv...
Charlie Berger
 
Oracle Open World 2018 / Code One : MySQL 8.0 Document Store
Frederic Descamps
 
pre-FOSDEM MySQL day, February 2018 - MySQL Document Store
Frederic Descamps
 
MySQL User Group NL: MySQL 8.0 Document Store- NoSQL with all the benefits of...
Frederic Descamps
 
DataOps barcelona - MySQL 8.0 document store: NoSQL with all the benefits of ...
Frederic Descamps
 
MySQL 8.0 Document Store - Discovery of a New World
Frederic Descamps
 
Oracle Code Event - MySQL JSON Document Store
Mark Swarbrick
 
Introduction to MySQL Document Store
Frederic Descamps
 
MySQL Document Store (Oracle Code Warsaw 2018)
Vittorio Cioe
 
Big data oracle_introduccion
Fran Navarro
 
The New Database Frontier: Harnessing the Cloud
Inside Analysis
 
Oracle PL/SQL 12c and 18c New Features + RADstack + Community Sites
Steven Feuerstein
 
はじめてのOracle Cloud Infrastructure(Oracle Cloudウェビナーシリーズ: 2020年6月24日)
オラクルエンジニア通信
 
A Step by Step Introduction to the MySQL Document Store
Dave Stokes
 
Database Basics with PHP -- Connect JS Conference October 17th, 2015
Dave Stokes
 
DOAG Big Data Days 2017 - Cloud Journey
Harald Erb
 
Why Use an Oracle Database?
Markus Michalewicz
 
Oracle NoSQL
Oracle Korea
 
MySQL 8.0 Introduction to NoSQL + SQL
Manuel Contreras
 
Joe Celko s SQL for Smarties Fourth Edition Advanced SQL Programming Joe Celko
joaraepri
 
Oracle Database House Party_Oracle Machine Learning to Pick a Good Inexpensiv...
Charlie Berger
 
Ad

More from Frederic Descamps (20)

PDF
MySQL Innovation & Cloud Day - Document Store avec MySQL HeatWave Database Se...
Frederic Descamps
 
PDF
MySQL Day Roma - MySQL Shell and Visual Studio Code Extension
Frederic Descamps
 
PDF
RivieraJUG - MySQL Indexes and Histograms
Frederic Descamps
 
PDF
RivieraJUG - MySQL 8.0 - What's new for developers.pdf
Frederic Descamps
 
PDF
MySQL User Group NL - MySQL 8
Frederic Descamps
 
PDF
State of the Dolphin - May 2022
Frederic Descamps
 
PDF
Percona Live 2022 - MySQL Shell for Visual Studio Code
Frederic Descamps
 
PDF
Percona Live 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
PDF
Percona Live 2022 - MySQL Architectures
Frederic Descamps
 
PDF
LinuxFest Northwest 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
PDF
Open Source 101 2022 - MySQL Indexes and Histograms
Frederic Descamps
 
PDF
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Frederic Descamps
 
PDF
Confoo 2022 - le cycle d'une instance MySQL
Frederic Descamps
 
PDF
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
Frederic Descamps
 
PDF
Les nouveautés de MySQL 8.0
Frederic Descamps
 
PDF
Les nouveautés de MySQL 8.0
Frederic Descamps
 
PDF
State of The Dolphin - May 2021
Frederic Descamps
 
PDF
MySQL Shell for DBAs
Frederic Descamps
 
PDF
Deploying Magento on OCI with MDS
Frederic Descamps
 
PDF
MySQL Router REST API
Frederic Descamps
 
MySQL Innovation & Cloud Day - Document Store avec MySQL HeatWave Database Se...
Frederic Descamps
 
MySQL Day Roma - MySQL Shell and Visual Studio Code Extension
Frederic Descamps
 
RivieraJUG - MySQL Indexes and Histograms
Frederic Descamps
 
RivieraJUG - MySQL 8.0 - What's new for developers.pdf
Frederic Descamps
 
MySQL User Group NL - MySQL 8
Frederic Descamps
 
State of the Dolphin - May 2022
Frederic Descamps
 
Percona Live 2022 - MySQL Shell for Visual Studio Code
Frederic Descamps
 
Percona Live 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
Percona Live 2022 - MySQL Architectures
Frederic Descamps
 
LinuxFest Northwest 2022 - The Evolution of a MySQL Database System
Frederic Descamps
 
Open Source 101 2022 - MySQL Indexes and Histograms
Frederic Descamps
 
Pi Day 2022 - from IoT to MySQL HeatWave Database Service
Frederic Descamps
 
Confoo 2022 - le cycle d'une instance MySQL
Frederic Descamps
 
FOSDEM 2022 MySQL Devroom: MySQL 8.0 - Logical Backups, Snapshots and Point-...
Frederic Descamps
 
Les nouveautés de MySQL 8.0
Frederic Descamps
 
Les nouveautés de MySQL 8.0
Frederic Descamps
 
State of The Dolphin - May 2021
Frederic Descamps
 
MySQL Shell for DBAs
Frederic Descamps
 
Deploying Magento on OCI with MDS
Frederic Descamps
 
MySQL Router REST API
Frederic Descamps
 
Ad

Recently uploaded (20)

PDF
“Squinting Vision Pipelines: Detecting and Correcting Errors in Vision Models...
Edge AI and Vision Alliance
 
PPTX
Digital Circuits, important subject in CS
contactparinay1
 
PPTX
Mastering ODC + Okta Configuration - Chennai OSUG
HathiMaryA
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
PDF
[Newgen] NewgenONE Marvin Brochure 1.pdf
darshakparmar
 
PPTX
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
PDF
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 
PPTX
Seamless Tech Experiences Showcasing Cross-Platform App Design.pptx
presentifyai
 
PDF
“Computer Vision at Sea: Automated Fish Tracking for Sustainable Fishing,” a ...
Edge AI and Vision Alliance
 
PPTX
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
PDF
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
PPTX
Designing_the_Future_AI_Driven_Product_Experiences_Across_Devices.pptx
presentifyai
 
PDF
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
PPTX
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
PPTX
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
PDF
NLJUG Speaker academy 2025 - first session
Bert Jan Schrijver
 
PDF
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
PDF
Kit-Works Team Study_20250627_한달만에만든사내서비스키링(양다윗).pdf
Wonjun Hwang
 
PDF
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
“Squinting Vision Pipelines: Detecting and Correcting Errors in Vision Models...
Edge AI and Vision Alliance
 
Digital Circuits, important subject in CS
contactparinay1
 
Mastering ODC + Okta Configuration - Chennai OSUG
HathiMaryA
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
[Newgen] NewgenONE Marvin Brochure 1.pdf
darshakparmar
 
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
POV_ Why Enterprises Need to Find Value in ZERO.pdf
darshakparmar
 
Seamless Tech Experiences Showcasing Cross-Platform App Design.pptx
presentifyai
 
“Computer Vision at Sea: Automated Fish Tracking for Sustainable Fishing,” a ...
Edge AI and Vision Alliance
 
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
Designing_the_Future_AI_Driven_Product_Experiences_Across_Devices.pptx
presentifyai
 
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
NLJUG Speaker academy 2025 - first session
Bert Jan Schrijver
 
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
Kit-Works Team Study_20250627_한달만에만든사내서비스키링(양다윗).pdf
Wonjun Hwang
 
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 

Oracle Code Roma: NoSQL + SQL = MySQL

  • 2. 2 / 1002 / 100
  • 3.   Safe Harbor Statement The following is intended to outline our general product direction. It is intended for information purpose only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied up in making purchasing decisions. The development, release and timing of any features or functionality described for Oracle´s product remains at the sole discretion of Oracle. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 3 / 100
  • 4. about me - http://about.me/lefred Who am I ? Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 4 / 100
  • 5. Frédéric Descamps @lefred MySQL Evangelist Hacking MySQL since 3.23 devops believer living in Belgium 🇧🇪 http://lefred.be   Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 5 / 100
  • 6. MySQL a Document Store with all the benefits of a RDBMS Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 6 / 100
  • 7. Why ? Developers don´t really like SQL   Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 7 / 100
  • 8. Why ? SQL can be complicated and slows down the initial development Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 8 / 100
  • 9. easy operations What do developers want ? Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 9 / 100
  • 10. Use Objects / Documents Developers want just to use objects Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 10 / 100
  • 11. Use Objects / Documents Developers want just to use objects that´s why they usually love what DBAs hate the most ORMs !). Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 11 / 100
  • 12. Use Objects / Documents Developers want just to use objects that´s why they usually love what DBAs hate the most ORMs !). They want to deal with these objects easily (CRUD operations) and they don´t want to think about schema design (slows down the initial development process). Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 12 / 100
  • 13. Use Objects / Documents Developers want just to use objects that´s why they usually love what DBAs hate the most ORMs !). They want to deal with these objects easily (CRUD operations) and they don´t want to think about schema design (slows down the initial development process). But they also want to keep their data safe and use transactions. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 13 / 100
  • 14. RDBMS & MySQL Relational Databases Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 14 / 100
  • 15. Relational Databases Data Integrity Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 15 / 100
  • 16. Relational Databases Data Integrity normalization Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 16 / 100
  • 17. Relational Databases Data Integrity normalization constraints (foreign keys, ...) Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 17 / 100
  • 18. Relational Databases Data Integrity normalization constraints (foreign keys, ...) Atomicity, Consistency, Isolation, Durability Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 18 / 100
  • 19. Relational Databases Data Integrity normalization constraints (foreign keys, ...) Atomicity, Consistency, Isolation, Durability ACID compliant Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 19 / 100
  • 20. Relational Databases Data Integrity normalization constraints (foreign keys, ...) Atomicity, Consistency, Isolation, Durability ACID compliant transactions Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 20 / 100
  • 21. Relational Databases Data Integrity normalization constraints (foreign keys, ...) Atomicity, Consistency, Isolation, Durability ACID compliant transactions SQL Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 21 / 100
  • 22. Relational Databases Data Integrity normalization constraints (foreign keys, ...) Atomicity, Consistency, Isolation, Durability ACID compliant transactions SQL powerfull query language Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 22 / 100
  • 23. NoSQL & MySQL NoSQL Databases Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 23 / 100
  • 24. NoSQL or Document Store Schemaless Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 24 / 100
  • 25. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 25 / 100
  • 26. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 26 / 100
  • 27. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 27 / 100
  • 28. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure embedded arrays or objects Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 28 / 100
  • 29. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure embedded arrays or objects valid solution when natural data can´t be modelized optimaly into a relational model Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 29 / 100
  • 30. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure embedded arrays or objects valid solution when natural data can´t be modelized optimaly into a relational model objects persistance without the use of any ORM - mapping oobject-oriented Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 30 / 100
  • 31. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure embedded arrays or objects valid solution when natural data can´t be modelized optimaly into a relational model objects persistance without the use of any ORM - mapping oobject-oriented JSON Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 31 / 100
  • 32. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure embedded arrays or objects valid solution when natural data can´t be modelized optimaly into a relational model objects persistance without the use of any ORM - mapping oobject-oriented JSON close to frontend Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 32 / 100
  • 33. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure embedded arrays or objects valid solution when natural data can´t be modelized optimaly into a relational model objects persistance without the use of any ORM - mapping oobject-oriented JSON close to frontend native in JS Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 33 / 100
  • 34. NoSQL or Document Store Schemaless no schema design, no normalization, no foreign keys, no data types, ... very quick initial development Flexible data structure embedded arrays or objects valid solution when natural data can´t be modelized optimaly into a relational model objects persistance without the use of any ORM - mapping oobject-oriented JSON close to frontend native in JS easy to learn Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 34 / 100
  • 35. How DBAs see data Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 35 / 100
  • 36. How DBAs see data How Developers see data { "GNP" : 249704, "Name" : "Belgium", "government" : { "GovernmentForm" : "Constitutional Monarchy, Federation", "HeadOfState" : "Philippe I" }, "_id" : "BEL", "IndepYear" : 1830, "demographics" : { "Population" : 10239000, "LifeExpectancy" : 77.8000030517578 }, "geography" : { "Region" : "Western Europe", "SurfaceArea" : 30518, "Continent" : "Europe" } } Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 36 / 100
  • 37. What if there was a way to provide both SQL and NoSQL on one stable platform that has proven stability on well know technology with a large Community and a diverse ecosystem ? Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 37 / 100
  • 38. DBMS or NoSQL ? Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 38 / 100
  • 39. DBMS or NoSQL ? Why not both ? Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 39 / 100
  • 40. The MySQL Document Store ! SQL is now optional ?! Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 40 / 100
  • 41. SQL is now optional ?! Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 41 / 100
  • 42. Developers: [x] schemaless [x] rapid prototying/simpler APIs [x] document model [x] transactions Operations: [x] performance management/visibility [x] robust replication, backup, restore [x] comprehensive tooling ecosystem [x] simpler application schema upgrades Business Owner: [x] don't lose my data == ACID trx [x] capture all my data = extensible/schemaless [x] product on schedule/time to market = rapid developement A solution for all Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 42 / 100
  • 43. MySQL Document Store the Solution Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 43 / 100
  • 44. Built on the MySQL JSON Data type and Proven MySQL Server Technology Provides a schema flexible JSON Document Store No SQL required No need to define all possible attributes, tables, etc. Uses new X DevAPI Can leverage generated column to extract JSON values into materialized columns that can be indexed for fast SQL searches. Document can be ~1GB It's a column in a row of a table It cannot exceed max_allowed_packet Allows use of modern programming styles No more embedded strings of SQL in your code Easy to read Also works with relational Tables Proven MySQL Technology Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 44 / 100
  • 45. X Protocol Connectors Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 45 / 100
  • 46. X DevAPI We provide connectors for C++, Java, .Net, Node.js, Python, PHP working with Communities to help them supporting it too New MySQL Shell Command Completion Python, JavaScrips & SQL modes Admin functions New Util object A new high-level session concept that can scale from single MySQL Server to a multiple server environment Non-blocking, asynchronous calls follow common language patterns Supports CRUD operations Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 46 / 100
  • 47. PY JS SQL > MySQL 8.0 Upgrade Checker Auto Completion & Command History Output Formats (table, json, tabs) Prompt Themes Batch Execution 5.7 8.0 JS Document Store X dev API SQL CLI InnoDB Cluster importJSON JSJS Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 47 / 100
  • 48. Migration from MongoDB to MySQL DS For this example, I will use the well known restaurants collection: Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 48 / 100
  • 49. Migration from MongoDB to MySQL DS For this example, I will use the well known restaurants collection: Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 49 / 100
  • 50. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 50 / 100
  • 51. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 51 / 100
  • 52. Let´s query Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 52 / 100
  • 53. Let´s query That´s too much records to show it here... let´s limit it Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 53 / 100
  • 54. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 54 / 100
  • 55. Some more examples Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 55 / 100
  • 56. Some more examples Let´s add a selection criteria: Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 56 / 100
  • 57. Using IN... Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 57 / 100
  • 58. Syntax slightly different than MongoDB Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 58 / 100
  • 59. Syntax slightly different than MongoDB > db.restaurants. nd({"cuisine": "French", "borough": { $not: /^Manhattan/} }, {"_id":0, "name": 1,"cuisine": 1, "borough": 1}).limit(2) { "borough" : "Queens", "cuisine" : "French", "name" : "La Baraka Restaurant" } { "borough" : "Queens", "cuisine" : "French", "name" : "Air France Lounge" } Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 59 / 100
  • 60. And for developers ? Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 60 / 100
  • 61. And for developers ? $session = mysql_xdevapigetSession("mysqlx://fred:MyP@ssw0rd%@localhost"); $schema = $session->getSchema("docstore"); $collection = $schema->getCollection("restaurants"); $results = $collection-> nd($search)->execute()->fetchAll(); ... foreach ($results as $doc) { echo "<tr><td><a href='?id=${doc[_id]}'>${doc[name]}</a></td>"; echo "<td>${doc[borough]}</td><td>${doc[cuisine]}</td></tr>"; } Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 61 / 100
  • 62. And for developers ? $session = mysql_xdevapigetSession("mysqlx://fred:MyP@ssw0rd%@localhost"); $schema = $session->getSchema("docstore"); $collection = $schema->getCollection("restaurants"); $results = $collection-> nd($search)->execute()->fetchAll(); ... foreach ($results as $doc) { echo "<tr><td><a href='?id=${doc[_id]}'>${doc[name]}</a></td>"; echo "<td>${doc[borough]}</td><td>${doc[cuisine]}</td></tr>"; }   Easy, using only CRUD operations ! Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 62 / 100
  • 63. CRUD operations Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 63 / 100
  • 64. CRUD operations for collections Add a document Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 64 / 100
  • 65. CRUD operations for collections Add a document collection.add({ name: 'fred', age: 42 }) .add({ name: 'dave', age: 23 }) .execute() collection.add([ { name: 'dimo', age: 50 }, { name: 'kenny', age: 25 } ]).execute() Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 65 / 100
  • 66. CRUD operations for collections Modify a document Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 66 / 100
  • 67. CRUD operations for collections Modify a document collection.modify('name = :name') .bind('name', 'fred') .set('age', 43) .sort('name ASC') .limit(1) .execute() collection.modify('name = :name') .bind('name', 'fred') .patch({ age: 43, active: false }) .sort('name DESC') .limit(1) .execute() Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 67 / 100
  • 68. CRUD operations for collections Remove a document Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 68 / 100
  • 69. CRUD operations for collections Remove a document collection.remove('name = :name') .bind('name', 'fred') .sort('age ASC') .limit(1) .execute() Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 69 / 100
  • 70. MySQL Document Store Objects Summary Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 70 / 100
  • 71. All you need to know is here: https://dev.mysql.com/doc/x-devapi-userguide/en/crud-operations-overview.html Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 71 / 100
  • 72. we do care about your data MySQL Document Store is Full ACID Compliant Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 72 / 100
  • 73. Document Store Full ACID ! It relies on the proven MySQL InnoDB´s strength & robustness: Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 73 / 100
  • 74. Document Store Full ACID ! It relies on the proven MySQL InnoDB´s strength & robustness: innodb_ ush_log_at_trx_commit = 1 Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 74 / 100
  • 75. Document Store Full ACID ! It relies on the proven MySQL InnoDB´s strength & robustness: innodb_ ush_log_at_trx_commit = 1 innodb_doublewrite = ON Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 75 / 100
  • 76. Document Store Full ACID ! It relies on the proven MySQL InnoDB´s strength & robustness: innodb_ ush_log_at_trx_commit = 1 innodb_doublewrite = ON sync_binlog = 1 Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 76 / 100
  • 77. Document Store Full ACID ! It relies on the proven MySQL InnoDB´s strength & robustness: innodb_ ush_log_at_trx_commit = 1 innodb_doublewrite = ON sync_binlog = 1 transaction_isolation = REPEATABLE-READ|READ- COMMITTED|... Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 77 / 100
  • 78. Document Store Full ACID ! It relies on the proven MySQL InnoDB´s strength & robustness: innodb_ ush_log_at_trx_commit = 1 innodb_doublewrite = ON sync_binlog = 1 transaction_isolation = REPEATABLE-READ|READ- COMMITTED|... We do care about your data ! Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 78 / 100
  • 79. MySQL DS Full ACID - Transactions support Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 79 / 100
  • 80. MySQL DS Full ACID - Transactions support Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 80 / 100
  • 81. OK we have Document Store, CRUD and ACID but what makes MySQL Document Store unique ? Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 81 / 100
  • 82. Challenge: list the best restaurant of each type of food and show the top 10, with the best one first !   don't forget that all these restaurants are just JSON documents Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 82 / 100
  • 83. NoSQL as SQL - aggregation Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 83 / 100
  • 84. NoSQL as SQL - aggregation Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 84 / 100
  • 85. NoSQL as SQL - aggregation Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 85 / 100
  • 86. NoSQL or SQL You have the possibility to write clean and neat code: Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 86 / 100
  • 87. NoSQL or SQL You have the possibility to write clean and neat code: $results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll(); Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 87 / 100
  • 88. NoSQL or SQL You have the possibility to write clean and neat code: $results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll(); Or use SQL only when really needed: Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 88 / 100
  • 89. NoSQL or SQL You have the possibility to write clean and neat code: $results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll(); Or use SQL only when really needed: $results = $session->sql('WITH cte1 AS (SELECT doc->>"$.name" AS name, doc->>"$.cuisine" AS cuisine, (SELECT AVG(score) FROM JSON_TABLE(doc, "$.grades[*]" COLUMNS (score INT PATH "$.score")) AS r) AS avg_score FROM docstore.restaurants) SELECT *, RANK() OVER ( PARTITION BY cuisine ORDER BY avg_score) AS `rank` FROM cte1 ORDER BY `rank`, avg_score DESC LIMIT 10;')->execute(); Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 89 / 100
  • 90. NoSQL or SQL You have the possibility to write clean and neat code: $results = $collection-> nd('cuisine like "italian"')->execute()->fetchAll(); Or use SQL only when really needed: $results = $session->sql('WITH cte1 AS (SELECT doc->>"$.name" AS name, doc->>"$.cuisine" AS cuisine, (SELECT AVG(score) FROM JSON_TABLE(doc, "$.grades[*]" COLUMNS (score INT PATH "$.score")) AS r) AS avg_score FROM docstore.restaurants) SELECT *, RANK() OVER ( PARTITION BY cuisine ORDER BY avg_score) AS `rank` FROM cte1 ORDER BY `rank`, avg_score DESC LIMIT 10;')->execute(); All in the same MySQL X Session ! Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 90 / 100
  • 91. MySQL Shell is for DBAs and Developers     DEMO Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 91 / 100
  • 92. what do I gain ? Conclusion Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 92 / 100
  • 93. schemaless flexible data structure easy to start (CRUD) Conclusion This is the best of the two worlds in one product ! Data integrity ACID Compliant Transactions SQL Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 93 / 100
  • 95. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 95 / 100
  • 97. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 97 / 100
  • 98.   May 9th, 2019 Hotel NH Collection Roma Giustiniano Via Virgilio, 1 E/F/G, 0019 ROMA MySQL Day Roma You are invited to listen last news on MySQL 8.0, watch demos and be in contact with the MySQL Italian Team! http://bit.ly/MySQLDayRoma2019 Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 98 / 100
  • 99. Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 99 / 100
  • 100. Thank you ! Any Questions ? share your 💕 for MySQL on social media using @mysql #MySQL8isGreat #MySQL Copyright @ 2019 Oracle and/or its affiliates. All rights reserved. 100 / 100