Home |  MySQL Buzz |  FAQ |  Feeds |  Submit your blog feed |  Feedback |  Archive |  Aggregate feed RSS 2.0 English Deutsch Español Français Italiano 日本語 Русский Português 中文
Previous 30 Newer Entries Showing entries 61 to 90 of 762 Next 30 Older Entries

Displaying posts with tag: Uncategorized (reset)

More on cost-based choice between subquery Materialization and IN->EXISTS
+0 Vote Up -0Vote Down

In my previous post, I shared my finding that MySQL 5.6.7 does not make a cost-based choice between Materialization and IN-to-EXISTS strategies for subqueries.

It turns out I was wrong. As Guilhem Bichot has blogged here, he has implemented cost-based choice between Materialization and IN->EXISTS in MySQL 5.6.7. Igor Babaev also wrote about the topic, and covered the reasons I didn’t see the feature - it isn’t mentioned in the documentation, development process at Oracle is quite closed, and the feature didn’t work for a basic example that I have tried.

Let’s try to focus on the technical part of it. Looking at the source code, I see that

  [Read more...]
MySQL IN AND OR
+0 Vote Up -0Vote Down

MySQL IN??? MySQL OR??? MySQL AND???
When I use one and when I use other?

we will use the city table to this tutorial:

+-------------+----------+------+-----+---------+----------------+
| Field       | Type     | Null | Key | Default | Extra          |
+-------------+----------+------+-----+---------+----------------+
| ID          | int(11)  | NO   | PRI | NULL    | auto_increment |
| Name        | char(35) | NO   |     |         |                |
| CountryCode | char(3)  | NO   | MUL |         |                |
| District    | char(20) | NO   |     |         |                |
| Population  | int(11)  | NO   |     | 0       |                |
+-------------+----------+------+-----+---------+----------------+



Let’s see a simple rule to clarify this:

AND – we use AND to add a new condition which will need to be


  [Read more...]
Swedish MySQL Users Group Meeting
Employee +2 Vote Up -0Vote Down

Stockholm will host the Swedish MySQL Users Group on November 21st and the details can be found at http://www.facebook.com/events/468752256510179/

We will talk about news from MySQL Connect, which was a few weeks ago, especially if 5.6RC course! * We will have a review of partitioning with a developer who has worked with just that. * Our last point is a review of a beloved children – character sets in MySQL. One common source of headaches.


Two Cons against NoSQL. Part I.
+1 Vote Up -1Vote Down
Two cons against NoSQL data stores read like this: 1. It’s very hard to move data out from one NoSQL to some other system, even other NoSQL. There is a very hard lock in when it comes to NoSQL. If you ever have to move to another database, you have basically to re-implement a lot [...]
Recording session on MySQL
+0 Vote Up -0Vote Down

Hi guys, today let’s learn about a very useful option on mysql command line to recording all what happen in your mysql session, It’s the option –tee. Is very easy to use, you just need to add the –tee=/path/to/file

mysql -u root -p --tee=/tmp/log.mysql

It is all for today!
Enjoy!!!

On Eventual Consistency– Interview with Monty Widenius.
+1 Vote Up -0Vote Down
“For analytical things, eventual consistency is ok (as long as you can know after you have run them if they were consistent or not). For real world involving money or resources it’s not necessarily the case.” — Michael “Monty” Widenius. In a recent interview, I asked Justin Sheehy, Chief Technology Officer at Basho Technologies, maker [...]
On Eventual Consistency — An interview with Michael Monty Widenius.
+0 Vote Up -1Vote Down
“For analytical things, eventual consistency is ok (as long as you can know after you have run them if they were consistent or not). For real world involving money or resources it’s not necessarily the case.” — Michael “Monty” Widenius. In a recent interview, I asked Justin Sheehy, Chief Technology Officer at Basho Technologies, maker [...]
Slides and Other Files From My Hands-On Labs at MySQL Connect 2012
Employee_Team +3 Vote Up -0Vote Down

First of all a big thank you to all of you who attended my two Hands-On Labs (HOL) session at this year’s MySQL Connect. I ended up doing two sessions as there was a last minute cancellation, so in addition to the previously announced session about the Performance Schema, I also did an introduction to MySQL.

The slides and the workbook for the Performance Schema session will become available from the official Oracle OpenWorld/MySQL Connect catalog, but you can also get the files from my blog which for the Performance Schema

  [Read more...]
Austin MySQL Meetup on Monday
Employee +1 Vote Up -0Vote Down

The Austin MySQL Meetup is this Monday 7PM sharp at the Oracle office at 5300 Riata Park Court Building B. Please RSVP so we can order enough pizza!


Comparison of subquery optimizations in MySQL 5.6 and MariaDB 5.5
+5 Vote Up -0Vote Down

MySQL 5.6 is now RC, I suppose this means that all features that were intended to be in release are pushed, so it’s time to take a look and see what’s going to be in MySQL 5.6 GA.

I decided to look at subquery optimizations and compare them to what we’ve got in MariaDB 5.3/5.5. In case you don’t know, subquery optimizations in MySQL 5.6 and MariaDB come from a common ancestor - MySQL 6.0 alpha, which was released in spring 2009 and then abandoned because there were too many unstable features pushed into it.

Then, both MariaDB team and Oracle salvaged subquery code out of the 6.0 mess, and worked to get it in shape for release. MariaDB released its results in GA quality in April 2012 as MariaDB 5.3, which was quickly followed by MariaDB 5.5.

Inside

  [Read more...]
Scaling MySQL and MariaDB to TBs: Interview with Martín Farach-Colton.
+1 Vote Up -0Vote Down
“While I believe that one size fits most, claims that RDBMS can no longer keep up with modern workloads come in from all directions. When people talk about performance of databases on large systems, the root cause of their concerns is often the performance of the underlying B-tree index”– Martín Farach-Colton. Scaling MySQL and MariaDB [...]
October 8th — North Texas MySQL Users Group Meeting
Employee +1 Vote Up -0Vote Down

Last Month the Verizon folks asked for a presentation on MySQL Replication and so we will have one on Monday October 8th.  MySQL Replication is easy to setup, reliable, and MySQL 5.6 brings some new features such as Global Transaction Identifiers.  So some learn the basics and learn the new features. 

Starts at 5:00 PM! Please do not be late as the doors lock at 5PM and we will have to send someone to check on you!

Refreshments will be served!

Dallas – Irving Connection
6031 Connection Drive
Suite 900
Irving, TX 75039
Phone +1.972.652.8000


MySQL Visual Explain
Employee +3 Vote Up -0Vote Down

If you are tied of reading the old “text-only” output of MySQL Explain, then you will enjoy the new MySQL Visual Explain feature of MySQL Workbench (works with MySQL 5.6+).

Before:

mysql> explain select max(DepDelayMinutes), carrier, dayofweek from ontime.ontime_2010 where dayofweek = 7 group by Carrier, dayofweek\G
*************************** 1. row ***************************
id: 1
select_type: SIMPLE
table: ontime_2010
type: ref
possible_keys: DayOfWeek,dw_carr,covered
key: covered
key_len: 2
ref: const
rows: 1337314
Extra: Using where; Using index
1 row in set (0.00 sec)

After:














  [Read more...]
Top 10 MySQL Tips and Mistakes for PHP Developers (Webinar)
+1 Vote Up -0Vote Down

Tuesday, September 25, 2012

MySQL and PHP are two key components in the open-source LAMP stack, and are widely used by web developers. One day you launched a website, and it gradually gained traction and now serves hundreds times more traffic than day one. As a PHP developer, have you ever looked back and adjusted the MySQL configurations accordingly to meet the most current website load? Have you ever wondered if there are secret tips you might have missed or common mistakes that you could have avoided but never thought of? If you answered yes to either question, this presentation is for you!

In this live webinar, PHP & MySQL experts Ulf Wendel and Johannes Schlüter will share the top 10 tips and mistakes for PHP developers. After a quick overview of lesser known but cool client and server features and plugins, and a recap

  [Read more...]
The Optimiser Conundrum
+2 Vote Up -0Vote Down

We’ve been helping a long-term client who runs some fairly complex queries (covering lots of tables and logic on a respectably big but mainly volatile dataset). We tend to look first at query structure and table design, as fixing problems there tends to have the most impact. This contrary to just tossing more hardware at the problem, which is just expensive.

As subqueries are used (and necessary in this case), MariaDB 5.3 was already a great help with its subquery optimisations. Once again thanks, Monty and the Monty Program optimiser team (Igor, Sergey, Timour, and possibly others) – all former colleagues and they’re absolutely awesome. Together, they know the MySQL optimiser like no other.

Because the queries are generated indirectly from an exposed API (just for paying clients, but still), the load is more unpredictable than having merely a local front-end. Maintaining

  [Read more...]
ConFoo 2013: Call for Papers is Now Open!
+0 Vote Up -0Vote Down

ConFoo is one of the most important web developer-oriented conferences. ConFoo 2013 will be held on February 25 through March 1 in Montreal, Canada.

We just opened call for papers and we are looking for the best PHP, Java, Ruby, DotNet,HTML5 experts who are willing to share their knowledge with the Canadian community. Candidates can submit proposals until September 23. Consult the call for papers page for details and to start submitting. That page also explains what expenses ConFoo can cover for speakers. You can also get advice on how to write proposals.

The call for papers is public, meaning that all proposals get published on the website for others to

  [Read more...]
The Data Charmer: Is Oracle really killing MySQL?
+7 Vote Up -3Vote Down

http://datacharmer.blogspot.it/2012/08/is-oracle-really-killing-mysql.html

An insightful post for my former  (MySQL AB) colleague Giuseppe Maxia about how Oracle’s actions affect the MySQL landscape.

My own comment exploring why it’s happening (from Upstarta perspective) is on his blog post rather than here. From Open Query’s business perspective, we generally deploy MariaDB unless client prefers distro stock. We get the features we need in MariaDB, see the bugfixing and have an open dialog with the developers and see the development process.

While the current new code coming from Oracle definitely has interesting components, MariaDB has solved some real problems (such as subqueries), and

  [Read more...]
MySQL Workbench Utilities – Administer MySQL with Python Scripts
+4 Vote Up -0Vote Down

Over the next few months, I am going to be writing about the MySQL Utilities, and I will be posting links to each individual blog on this page.

If you haven’t heard of the MySQL Utilities (from the introduction to MySQL Utilities page):

“MySQL Utilities is a package of utilities that are used for maintenance and administration of MySQL servers. These utilities encapsulate a set of primitive commands, and bundles them so they can be used to perform macro operations with a single command. MySQL Utilities may be installed via MySQL Workbench, or as a standalone package. The utilities are written in

  [Read more...]
Dallas Oracle Users Group — MySQL 101 on September 4th
Employee +2 Vote Up -0Vote Down

Please join us at the DOUG (DALLAS ORACLE USERS GROUP) MySQL Forum meeting on Tuesday September 4th, 2011 from 5:00 pm – 6:30 pm (different than the usual meeting time, pizza BEFORE the meeting).

Presentation Overview
MySQL 101 — The Basics
Ever wanted to get started with MySQL? This presentation is an introduction that will cover installation, starting/stopping, monitoring, and administering MySQL. You will walk away from this meeting with the basic skills needed to run simple MySQL instances. Pre-install on your laptop and follow along!

Presented by Dave Stokes, MySQL Community Manager North America, Oracle Corporation

Refreshments will be served.

To RSVP for this meeting, click on



  [Read more...]
Great LA Audience last night, San Diego tonight
Employee +1 Vote Up -0Vote Down

Last night we had a great audience at the Los Angeles MySQL Users Group. And it is not too late to RSVP for the meeting of San Diego PHP.


SHOW EXPLAIN and skeletons in EXPLAIN’s closet
+7 Vote Up -0Vote Down

I believe I’m nearly done with the SHOW EXPLAIN feature. The idea is that if you’ve got some long-running query $LONG_QUERY running in connection $LONG_QUERY_CONN, you should be able to create another connection, run SHOW EXPLAIN FOR $LONG_QUERY_CONN and see what query plan is being used to run the $LONG_QUERY.

How is this different from just running explain $LONG_QUERY? First, you don’t need to replicate the exact environment that $LONG_QUERY was run in: you don’t need to figure out what values it had for @@optimizer_switch and other settings, what were the contents of its temporary tables, if any, what did InnoDB told the optimizer about the table statistics, etc.

Another, indirect benefit is that we will now be able to produce query’s EXPLAIN at arbitrary point in time,

  [Read more...]
NIST::NVD::Store::SQLite3 1.00.00
+0 Vote Up -0Vote Down

It’s been released. Use this with NIST::NVD 1.00.00 and you will be able to perform immediate look-ups of CVE and CWE data given a CPE URN. For instance:

cjac@foxtrot:/usr/src/git/f5/NIST-NVD-Store-SQLite3$ perl Makefile.PL ; make ; make test ; cjac@foxtrot:/usr/src/git/f5/NIST-NVD-Store-SQLite3$ perl -MNIST::NVD::Query -MData::Dumper -e '
$q = NIST::NVD::Query->new(store    => q{SQLite3},database => q{t/data/nvdcve-2.0.db});
$cve_list = $q->cve_for_cpe( cpe => q{cpe:/a:microsoft:ie:7.0.5730.11} );
print Data::Dumper::Dumper { cve_list => $cve_list, first_cvss => $q->cve( cve_id => $cve_list->[0] )->{q{vuln:cvss}} }
'
$VAR1 = {
          'cve_list' => [
                          'CVE-2002-2435',
                          'CVE-2010-5071'
                        ],
          'first_cvss' => {
  [Read more...]
Understanding SHOW VARIABLES: DISABLED and NO values
+1 Vote Up -0Vote Down

When you use SHOW VARIABLES LIKE “have_%” to see whether a particular feature is enabled, you will note the value of NO for some, and DISABLED for others. These values are not intrinsically clear for the casual onlooker, and often cause confusion. Typically, this happens with SSL and InnoDB. So, here is a quick clarification!

  • NO means that the feature was not enabled (or was actively disabled) in the build. This means the code and any required libraries are not present in the binary.
  • DISABLED means that the feature is built in and capable of working in the binary, but is disabled due to relevant my.cnf settings.
  • YES means the feature is available, and configured in my.cnf.

SSL tends to show up as DISABLED, until you configure

  [Read more...]
The 2012 Leap Second on Linux
+2 Vote Up -0Vote Down

Sheeri K. Cabral at the Mozilla Foundation wrote about an issue with the June 30th 2012 leap second affecting at least MySQL, Java and Minecraft servers. It now appears that the underlying cause is a Linux kernel bug, as noted by John Stultz (IBM) on the Linux Kernel mailing list, and the team Sheeri is part of deserves due credit for doing awesome pattern recognition and being the first to bring it to public attention, enabling people to quickly correlate their own experience with that of others and finding a practical solution as well as helping figure out the cause.

Sheeri’s original post MySQL and the Leap Second, High CPU and the Fix describes how MySQL servers would suddenly exhibit

  [Read more...]
INSERT, Don’t DELETE
+3 Vote Up -0Vote Down

I’ve been working on a data archival project over the last couple weeks and thought it would be interesting to discuss something a bit counter-intuitive. Absolutes are never true, but when getting rid of data, it’s usually more efficient to insert the data being kept into a new table rather than deleting the old data from the existing table.

Here is our example table from the IMDB database.

mysql> show create table title\G
*************************** 1. row ***************************
       Table: title
Create Table: CREATE TABLE `title` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `title` text NOT NULL,
  `imdb_index` varchar(12) DEFAULT NULL,
  `kind_id` int(11) NOT NULL,
  `production_year` int(11) DEFAULT NULL,
  `imdb_id` int(11) DEFAULT NULL,
  `phonetic_code`
  [Read more...]
Managing Internet Protocol Television Data. — An interview with Stefan Arbanowski.
+0 Vote Up -0Vote Down
” There is a variety of services possible via IPTV. Starting with live/linear TV and Video on Demand (VoD) over interactive broadcast related apps, like shopping or advertisement, up to social TV apps where communities of users have shared TV experience”– Stefan Arbanowski. The research center Fraunhofer FOKUS (Fraunhofer Institute for Open Communication Systems) in [...]
MySQL Connect & Oracle OpenWorld 2012
Employee +7 Vote Up -0Vote Down

Oracle OpenWorld 2012

I’m lucky enough to be involved in a number of sessions across Oracle OpenWorld as well as the (new for this year) MySQL Connect session that precedes it. MySQL Connect runs on Saturday 29th and Sunday 30th September and the Oracle OpenWorld on through Thursday October 4th.

The sessions I’ll be involved with are:

  [Read more...]
San Diego Users Group
Employee +2 Vote Up -0Vote Down

Come join the San Diego MySQL Users group on August 2nd for a look at MySQL 5.6 and help make some pizza disappear. The presentation will start at 7PM and all are welcome.

Oracle Office
9515 Towne Center Drive
San Diego, CA 92121


Server Ownership Legalities
+0 Vote Up -0Vote Down

As I reported via Twitter late last week, we encountered an issue that got some of our mail delivery delayed by about a day and a half. I’ll explain more about what happened as I believe in openness on these matters, and also the experience has educational content for others.

Our mail server doesn’t have direct external interaction, it’s shielded by two relays that handle both the inbound MX and the outbound queue. This setup works remarkably well in terms of exposure to spam and other malicious activity. As previously discussed, it appears that it’s more difficult to make mail server infra more resilient without expending lots more time/effort and infrastructure expenditure. Just because of the way the common tools for mail delivery and imap are built, having two or more of each in a semi-active setup gets quite complex. Complexity is in itself a risk so it has to

  [Read more...]
NOT IN with NULLs in the Subquery
+2 Vote Up -0Vote Down

A coworker came to me with a perplexing issue. He wanted to know why these two queries were not returning the same results:

mysql> SELECT COUNT(*) 
    -> FROM parent
    -> WHERE id NOT IN (SELECT parent_id FROM child);
+----------+
| count(*) |
+----------+
|        0 |
+----------+
1 row in set (7.84 sec)
mysql> SELECT COUNT(*)
    -> FROM parent p
    -> WHERE NOT EXISTS(SELECT 1 
    ->                  FROM child c
    ->                  WHERE p.id = c.parent_id);
+----------+
| count(*) |
+----------+
|     5575 |
+----------+
1 row in set (2.95 sec)

At first (and second, and third) glance these two queries look identical. It obviously is an exclusion join and because the MySQL optimizer is what it is, I

  [Read more...]
Previous 30 Newer Entries Showing entries 61 to 90 of 762 Next 30 Older Entries

Planet MySQL © 1995, 2013, Oracle Corporation and/or its affiliates   Legal Policies | Your Privacy Rights | Terms of Use

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.