Traditionally infrastructure management is a manual task, with sysadmins managing rather static servers. The automation capabilities of modern cloud platforms have changed this way of working: Infrastructure is often described “as code,” e.g. in a git repository, and changes are made by infrastructure management systems automatically. As a result infrastructure is much less static and turnaround […]
The following statement usually is valid and the function returns 1. But sometimes it is invalid and sometimes the function returns 0.
CREATE FUNCTION f() RETURNS INT DETERMINISTIC BEGIN DECLARE a CHAR DEFAULT 'a'; IF a = 0 || a > 0 THEN RETURN 1; END IF; RETURN 0; END;
Why?
First, consider that "||" is usually the same as "OR" because that's the default. But if sql_mode is 'ansi' and the DBMS is MySQL 8.0, then "||" is the operator for concatenating strings. So the meaning of the IF condition changes, and it becomes false.
Second, consider that the function is written with SQL/PSM syntax. But if sql_mode is 'oracle' and the DBMS is MariaDB 10.3, then the function has to be written with PL/SQL syntax. And the requirements differ as soon as the word "RETURNS" comes along, so the result is a syntax error.
Our lesson is: you can't know a statement's meaning if you don't know whether somebody said …
[Read more]
Peter Zaitsev of Percona posted a Tweet about an interactive
book Select Star SQL which 'aims to be the best place
on the internet for learning SQL'. This interactive book
uses a data set that can be downloaded or you could work the
queries online. I showed the website to a neighbor who was
asking 'what is the best way to learn SQL'. The
neighbor wanted their own copy of the data and asked how do you
turn a raw CSV file into a table.
Well, that can get complicated.
CSV
CSV files use commas to designate each field in the file.
This is a great idea until someone plants a comma in the middle
of a field but it is sort of a least common denominator way of
passing data between systems.
But a CSV file does not directly fit into a relational
table. You could …
Percona Monitoring and Management (PMM) is a free and open-source platform for managing and monitoring MySQL® and MongoDB® performance. You can run PMM in your own environment for maximum security and reliability. It provides thorough time-based analysis for MySQL® and MongoDB® servers to ensure that your data works as efficiently as possible.
We’ve included a plethora of visual improvements in this release, including:
- PostgreSQL Metrics Collection – Visualize PostgreSQL performance!
- Identify New Queries in Query Analytics
- New Dashboard: Compare System Parameters
- New Dashboard: PERFORMANCE_SCHEMA Wait Events Analysis
- Dashboard Updates – Advanced Data Exploration, MyRocks, TokuDB, InnoDB Metrics …
Codership is pleased to announce the release of Galera
Replication library 3.24, implementing wsrep API version
25. The new release includes improved deadlock
error management with foreign keys and security fixes.
As always, Galera Cluster is now available as targeted packages
and package repositories for a number of Linux distributions,
including Ubuntu, Red Hat, Debian, CentOS, OpenSUSE and SLES, as
well as FreeBSD. Obtaining packages using a package repository
removes the need to download individual files and facilitates the
easy deployment and upgrade of Galera Cluster
nodes.
This release incorporates all changes up to MySQL 5.7.23, MySQL 5.6.41 and MySQL 5.5.61.
Galera Replication Library 3.24
New features and notable fixes in Galera replication since last
binary release by Codership (3.23)
* A support for new …
[Read more]Do you need to modify the metrics collected from Linux by Percona Monitoring and Management (PMM)? In this blog post we will see how to enable, disable, and update collected metrics on PMM’s linux:metrics exporter.
We will assume that the PMM client packages are installed, and they are configured already.
Using a custom list of metrics
Let’s now suppose we are not yet collecting any metrics on our desired client server, and we want to enable only the following: diskstats, meminfo, netdev and vmstat. We can use the following …
[Read more]Please join Percona’s Chief Technology Officer, Vadim Tkachenko, as he presents Running MySQL in Kubernetes on Thursday, September 6th, 2018, at 11:00 AM PDT (UTC-7) / 2:00 PM EDT (UTC-4).
Without question, Kubernetes is the most popular container orchestration platform. But can it handle databases? I think so, and in this webinar, I will show you how it does it. This talk presents a quick overview of the persistent storage options (the most critical part of data storage) and then what it takes to run highly available MySQL …
[Read more]
A month ago, I wrote a blog on how you can configure the MySQL Shell prompt to suit your
needs. One thing I did not go into details with are the
prompt templates prompt_256pl.json
and
prompt_256pl+aw.json
. Common for both of these
templates is that they require custom fonts to work.
In the two file names, pl stands for the PowerLine fonts and aw for the Awesome font. These fonts add symbols that are useful to create rich prompts, not only for MySQL Shell, but also for Bash, zsh, vim, etc. The symbols include an angle separator, a lock (that in MySQL Shell is used to symbolize an TLS/SSL connection), and so on.
…
[Read more]In his excellent blog post, Pavel Trukhanov showed the value of S.M.A.R.T. metric collections, so I wondered how hard would it be to enable their collection in Percona Monitoring and Management (PMM)
A quick search led me to the text_collector plugin SmartMon, which can be easily integrated with any Prometheus Installation
For PMM, Vadim Yalovets recently showed how to do …
[Read more]Dear MySQL users,
MySQL Connector/Python 2.1.8 GA is a sixth GA version of 2.1
release
series of the pure Python database driver for MySQL. It can be
used for
production environments.
MySQL Connector/Python version 2.1.8 GA is compatible with MySQL
Server
versions 5.5 and greater. Python 2.6 and greater as well as
Python 3.4
and greater are supported. Python 2.4, 2.5, and 3.1, 3.2, 3.3 are
not
supported.
MySQL Connector/Python 2.1.8 is available for download from:
http://dev.mysql.com/downloads/connector/python/#downloads
MySQL Connector/Python 2.1.8 (Commercial) will be available for
download
on the My Oracle Support (MOS) website. This release will be
available
on eDelivery (OSDC) in next month’s upload cycle.
The ChangeLog file included in the …
[Read more]