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 中文
Showing entries 1 to 3

Displaying posts with tag: Discoveries (reset)

Who is the Subversion King in your Company?
+0 Vote Up -0Vote Down

Have you ever wanted to know who’s the top committer in your company?
In my previous company we etablished the term “CVS King”, a title comparable to “Employee of the month”. The developer with the most cvs commits was the “CVS King of the month”. We determined who was the “CSV King” using commit emails that were sent to all developers on each cvs commit.
Two years ago we switched to Subversion, so now we’re talking about the “Subversion King”. Naturally all this is anything but serious ;)

Anyway, today i programmed a little php script that uses a different approach to determine who is the “Subversion King of the Month”. It’s counting the line delta directly from the svn repository using



  [Read more...]
MySQL: Collation matters when using unique indexes
+0 Vote Up -0Vote Down

When using a uniqie index on a text field in mysql, the column collation setting is very important. The collation settings of a column does not only affect sorting and comparsion, but also unique indexes. So you can not insert "a" and "A" into a table that has a unique index on a column that has a case-insensitive collation. The mysql manual about collations: "A character set is a set of symbols and encodings. A collation is a set of rules for comparing characters in a character set."

Here is an example:
The column text in table text1 has a case-sensitive collation (_cs suffix), the column in text2 has a case-insensitive collation (_ci suffix).

PLAIN TEXT CODE:
  •  
  • CREATE TABLE text1 (

  •   [Read more...]
    Dynamic Materialized Views in MySQL
    +0 Vote Up -0Vote Down

    In one of my latest postings I mentioned a way to create semi materialized views in MySQL. The problem was that the solution required a stored procedure for every materialized view. That's very annoying. So I looked for a more general and dynamic approach. The result is another stored procedure with 3 parameters:

    • the name for the source table / view
    • the primary key columns of the source table / view
    • the desired name for the materialized view

    Basically this procedure does the following:

    • It drops the materialized view if it already exists
    • It creates the materialized view with the structure and data of the source table
    • It adds a primary key to the newly created materialized view

    However the procedure does not create triggers on the table.

      [Read more...]
    Showing entries 1 to 3

    Planet MySQL © 1995, 2014, 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.