Showing entries 361 to 370 of 5669
« 10 Newer Entries | 10 Older Entries »
Searching For: gp update (reset)
MySQL Query Attributes

Query attributes have in a long time been used to add metadata to queries to provide additional context such as where in the application the query was generated. The traditional way to do this is to add a comment at the start of the query with the attributes. Since the MySQL parser ignores the comment, it does not change the semantics of the query, but various tools can extract the comments.

This post looks into the reasons for using query attributes, how it is done using a comment, and the new component for MySQL 8.0.23 that provides native support for query attributes.

Advice

Query attributes are also known as query tags.

Why Query Attributes?

At the surface, it may seem that there is no major benefit from having metadata attached to a query – after all it is ignored by MySQL. However, there are good reasons. The …

[Read more]
New Book: MySQL Concurrency

In March 2020, my book MySQL 8 Query Performance Tuning (Apress) was released. That book with its more than 900 pages in 27 chapters covered a wide range of topics from executing benchmarks with sysbench over indexes and the optimizer to query rewriting, replication, and caching. Some time later my editor Jonathan Gennick suggested to take a limited set of the topics and go into more detail. We settled on locks and transactions which together have become MySQL Concurrency.

If you have already read MySQL 8 Query Performance Tuning, you may wonder what the new book offers compared to the previous one. In some way, you can think of MySQL Concurrency to be a second and expanded edition for the content on locks and transactions. Of course, given MySQL Concurrency is limited to those two topics, it has also been …

[Read more]
The MySQL X DevApi: Working with NULL Values

There was an excellent question from Francis on my MySQL X DevAPI tutorial on how to work with NULL values:

Is it possible to store an attribute with the null value, and how to find it (xxx is null ?

It may sound like a trivial question, but the answer is not all that simple, so instead of just replying directly to the comment, I think it is worth covering the subject of NULL values in the X DevAPI in a separate post.

The Short Story

In short there are two ways to work with “not a value” in the X DevAPI. One way is to not set a value for those fields in which case you can compare the retrieved values with IS NULL as you would for a relational table, for example in MySQL Connector/Python:

# Find documents where "Birthday IS NULL"
stmt_find = …
[Read more]
MySQL Invisible Column: part III

We recently saw how the new Invisible Column feature works in MySQL since 8.0.23 and how we can use it as a Primary Key for InnoDB tables when no Primary Key was defined.

As I wrote earlier, a good Primary Key is important for InnoDB (storage, IOPS, secondary indexes, memory…) but there is another important domain where a Primary Key is important in MySQL: replication !

Asynchronous Replication

When using “traditional” replication, if you modify a record (UPDATE and DELETE), the record(s) to modify on the replica are identified using indexes, and of course the Primary Key if any. The hidden global 6-bytes auto generated by InnoDB primary key is never used as never exposed and as it’s global, …

[Read more]
MySQL Invisible Column: part II

This article is the second part of the series related to MySQL Invisible Column started here.

This post covers why Invisible Column is important for InnoDB Storage Engine.

To start, let me explain briefly how InnoDB deals with Primary Key and why an good primary key is important. And finally, why having a Primary Key is also important.

How does InnoDB Stores Data?

InnoDB stores data in table spaces. The records are stored and sorted using the clustered index (the primary key): they are called index-organized tables.

All secondary indexes also contain the primary key as the right-most column in the index (even if this is not exposed). That means when a secondary …

[Read more]
Where's the MySQL Team from January - March 2021

As a continue of the regular blog posts informing you about where you can find MySQL Community & MySQL team at, please find below a list of shows you can join and listen MySQL talks & sessions. 

  • January 2021:

    • Coud Native Meetup/VIRTUAL, January 26, 2021 - URL to be provided later on.
      • Frederic Descamps, the MySQL User Group Manager will talk on: "MySQL 8.0: Why to use MySQL 8.0 and how to deploy a web application in OCI using MySQL Database Service" 
      • Scheduled for January 26th as EMEA & JAPAC session & January 27th, 2021.
    • OpenSource Conference Osaka/VIRTUAL, January 30, 2021
      • Yoshiaki Yamasaki, the MySQL …
[Read more]
MySQL Shell 8.0.23 for MySQL Server 8.0 and 5.7 has been released

Dear MySQL users,

MySQL Shell 8.0.23 is a maintenance release of MySQL Shell 8.0 Series (a
component of the MySQL Server). The MySQL Shell is provided under
Oracle’s dual-license.

MySQL Shell 8.0 is highly recommended for use with MySQL Server 8.0 and
5.7. Please upgrade to MySQL Shell 8.0.23.

MySQL Shell is an interactive JavaScript, Python and SQL console
interface, supporting development and administration for the MySQL
Server. It provides APIs implemented in JavaScript and Python that
enable you to work with MySQL InnoDB cluster and use MySQL as a document
store.

The AdminAPI enables you to work with MySQL InnoDB cluster and InnoDB
ReplicaSet, providing integrated solutions for high availability and scalability
using InnoDB based MySQL databases, without requiring advanced MySQL
expertise.  For more …

[Read more]
Working With MyISAM in MySQL

MyISAM is one of the most popular storage engines in MySQL. MyISAM frequently is the second choice after InnoDB - in this blog post we will try to find out how best to work with this engine.

What is MyISAM?

MyISAM is one of MySQL’s storage engines. MyISAM is based on ISAM (Indexed Sequential Access Method), an indexing algorithm developed by IBM that allows retrieving information from large sets of data in a fast way. However, it does not do very well when simultaneously reading from and writing to one table, due to its table locking. It also does not support transactions.

For some MySQL engineers, this engine is the most popular choice after InnoDB: the …

[Read more]
Generating Flexible Random data in MySQL

I was about to benchmark the various compression methods in MySQL ( Via Engines ). But i liked to simulate my own data set similar to a production work load. Well searched for a tool which should be flexible to enough make customised table structure and more.

Mysql_random_data_load is a tool from Percona labs used to manipulate random data based on flexible table structure. This seems like a right fit for our benchmarking needs.

Let’s explore this tool to work efficiently on it.

MySQL Random Data Load :

Mysql_random_data_load will load (insert) ‘n’ number of records to the source table and populate it with random data based on data type. So this tool won’t determine the predefined table column or data type like sysbench. It will insert data into the table based on column data type. Thus we …

[Read more]
PHP CRUD Application – Portfolio Piece

I am super pleased to share that I have completed and uploaded my first (that I can share at least) personal portfolio piece written in PHP to a subdomain on my personal hosting server located at walk.openlamp.tech. Over the better part of the last year, I have developed a custom reporting dashboard written in PHP for my (current) employer, but do not share any of that work as it is proprietary and not owned by me. However, for a personal project, I can share far and wide. In this post, I provide a brief overview of my simple (in theory at least) application/site, built on the LAMP stack using the MVC (Model-View-Controller) design pattern in core PHP along with Bootstrap 4, jQuery, and MySQL.

Image by …

[Read more]
Showing entries 361 to 370 of 5669
« 10 Newer Entries | 10 Older Entries »