mirror of
https://github.com/MariaDB/server.git
synced 2025-01-31 19:11:46 +01:00
local merge
This commit is contained in:
commit
72ffdcb2a5
35 changed files with 12028 additions and 358 deletions
523
COPYING
523
COPYING
|
@ -1,352 +1,339 @@
|
|||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 2, June 1991
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 2, June 1991
|
||||
|
||||
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
|
||||
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
|
||||
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
|
||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
Preamble
|
||||
|
||||
Preamble
|
||||
========
|
||||
|
||||
The licenses for most software are designed to take away your freedom
|
||||
to share and change it. By contrast, the GNU General Public License is
|
||||
intended to guarantee your freedom to share and change free
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
License is intended to guarantee your freedom to share and change free
|
||||
software--to make sure the software is free for all its users. This
|
||||
General Public License applies to most of the Free Software
|
||||
Foundation's software and to any other program whose authors commit to
|
||||
using it. (Some other Free Software Foundation software is covered by
|
||||
the GNU Library General Public License instead.) You can apply it to
|
||||
the GNU Lesser General Public License instead.) You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not price.
|
||||
Our General Public Licenses are designed to make sure that you have
|
||||
the freedom to distribute copies of free software (and charge for this
|
||||
service if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs; and that you know you can do these things.
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
this service if you wish), that you receive source code or can get it
|
||||
if you want it, that you can change the software or use pieces of it
|
||||
in new free programs; and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid anyone
|
||||
to deny you these rights or to ask you to surrender the rights. These
|
||||
restrictions translate to certain responsibilities for you if you
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
anyone to deny you these rights or to ask you to surrender the rights.
|
||||
These restrictions translate to certain responsibilities for you if you
|
||||
distribute copies of the software, or if you modify it.
|
||||
|
||||
For example, if you distribute copies of such a program, whether gratis
|
||||
or for a fee, you must give the recipients all the rights that you
|
||||
have. You must make sure that they, too, receive or can get the source
|
||||
code. And you must show them these terms so they know their rights.
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must give the recipients all the rights that
|
||||
you have. You must make sure that they, too, receive or can get the
|
||||
source code. And you must show them these terms so they know their
|
||||
rights.
|
||||
|
||||
We protect your rights with two steps: (1) copyright the software, and
|
||||
We protect your rights with two steps: (1) copyright the software, and
|
||||
(2) offer you this license which gives you legal permission to copy,
|
||||
distribute and/or modify the software.
|
||||
|
||||
Also, for each author's protection and ours, we want to make certain
|
||||
Also, for each author's protection and ours, we want to make certain
|
||||
that everyone understands that there is no warranty for this free
|
||||
software. If the software is modified by someone else and passed on, we
|
||||
want its recipients to know that what they have is not the original, so
|
||||
that any problems introduced by others will not reflect on the original
|
||||
authors' reputations.
|
||||
|
||||
Finally, any free program is threatened constantly by software patents.
|
||||
We wish to avoid the danger that redistributors of a free program will
|
||||
individually obtain patent licenses, in effect making the program
|
||||
proprietary. To prevent this, we have made it clear that any patent
|
||||
must be licensed for everyone's free use or not licensed at all.
|
||||
Finally, any free program is threatened constantly by software
|
||||
patents. We wish to avoid the danger that redistributors of a free
|
||||
program will individually obtain patent licenses, in effect making the
|
||||
program proprietary. To prevent this, we have made it clear that any
|
||||
patent must be licensed for everyone's free use or not licensed at all.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
0. This License applies to any program or other work which contains a
|
||||
notice placed by the copyright holder saying it may be distributed
|
||||
under the terms of this General Public License. The "Program",
|
||||
below, refers to any such program or work, and a "work based on
|
||||
the Program" means either the Program or any derivative work under
|
||||
copyright law: that is to say, a work containing the Program or a
|
||||
portion of it, either verbatim or with modifications and/or
|
||||
translated into another language. (Hereinafter, translation is
|
||||
included without limitation in the term "modification".) Each
|
||||
licensee is addressed as "you".
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
Activities other than copying, distribution and modification are
|
||||
not covered by this License; they are outside its scope. The act
|
||||
of running the Program is not restricted, and the output from the
|
||||
Program is covered only if its contents constitute a work based on
|
||||
the Program (independent of having been made by running the
|
||||
Program). Whether that is true depends on what the Program does.
|
||||
0. This License applies to any program or other work which contains
|
||||
a notice placed by the copyright holder saying it may be distributed
|
||||
under the terms of this General Public License. The "Program", below,
|
||||
refers to any such program or work, and a "work based on the Program"
|
||||
means either the Program or any derivative work under copyright law:
|
||||
that is to say, a work containing the Program or a portion of it,
|
||||
either verbatim or with modifications and/or translated into another
|
||||
language. (Hereinafter, translation is included without limitation in
|
||||
the term "modification".) Each licensee is addressed as "you".
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running the Program is not restricted, and the output from the Program
|
||||
is covered only if its contents constitute a work based on the
|
||||
Program (independent of having been made by running the Program).
|
||||
Whether that is true depends on what the Program does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Program's
|
||||
source code as you receive it, in any medium, provided that you
|
||||
conspicuously and appropriately publish on each copy an appropriate
|
||||
copyright notice and disclaimer of warranty; keep intact all the
|
||||
notices that refer to this License and to the absence of any
|
||||
warranty; and give any other recipients of the Program a copy of
|
||||
this License along with the Program.
|
||||
source code as you receive it, in any medium, provided that you
|
||||
conspicuously and appropriately publish on each copy an appropriate
|
||||
copyright notice and disclaimer of warranty; keep intact all the
|
||||
notices that refer to this License and to the absence of any warranty;
|
||||
and give any other recipients of the Program a copy of this License
|
||||
along with the Program.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy,
|
||||
and you may at your option offer warranty protection in exchange
|
||||
for a fee.
|
||||
You may charge a fee for the physical act of transferring a copy, and
|
||||
you may at your option offer warranty protection in exchange for a fee.
|
||||
|
||||
2. You may modify your copy or copies of the Program or any portion
|
||||
of it, thus forming a work based on the Program, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
of it, thus forming a work based on the Program, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a. You must cause the modified files to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
a) You must cause the modified files to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
b. You must cause any work that you distribute or publish, that
|
||||
in whole or in part contains or is derived from the Program
|
||||
or any part thereof, to be licensed as a whole at no charge
|
||||
to all third parties under the terms of this License.
|
||||
b) You must cause any work that you distribute or publish, that in
|
||||
whole or in part contains or is derived from the Program or any
|
||||
part thereof, to be licensed as a whole at no charge to all third
|
||||
parties under the terms of this License.
|
||||
|
||||
c. If the modified program normally reads commands interactively
|
||||
when run, you must cause it, when started running for such
|
||||
interactive use in the most ordinary way, to print or display
|
||||
an announcement including an appropriate copyright notice and
|
||||
a notice that there is no warranty (or else, saying that you
|
||||
provide a warranty) and that users may redistribute the
|
||||
program under these conditions, and telling the user how to
|
||||
view a copy of this License. (Exception: if the Program
|
||||
itself is interactive but does not normally print such an
|
||||
announcement, your work based on the Program is not required
|
||||
to print an announcement.)
|
||||
c) If the modified program normally reads commands interactively
|
||||
when run, you must cause it, when started running for such
|
||||
interactive use in the most ordinary way, to print or display an
|
||||
announcement including an appropriate copyright notice and a
|
||||
notice that there is no warranty (or else, saying that you provide
|
||||
a warranty) and that users may redistribute the program under
|
||||
these conditions, and telling the user how to view a copy of this
|
||||
License. (Exception: if the Program itself is interactive but
|
||||
does not normally print such an announcement, your work based on
|
||||
the Program is not required to print an announcement.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the
|
||||
Program, and can be reasonably considered independent and separate
|
||||
works in themselves, then this License, and its terms, do not
|
||||
apply to those sections when you distribute them as separate
|
||||
works. But when you distribute the same sections as part of a
|
||||
whole which is a work based on the Program, the distribution of
|
||||
the whole must be on the terms of this License, whose permissions
|
||||
for other licensees extend to the entire whole, and thus to each
|
||||
and every part regardless of who wrote it.
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Program,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Program, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or
|
||||
contest your rights to work written entirely by you; rather, the
|
||||
intent is to exercise the right to control the distribution of
|
||||
derivative or collective works based on the Program.
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Program.
|
||||
|
||||
In addition, mere aggregation of another work not based on the
|
||||
Program with the Program (or with a work based on the Program) on
|
||||
a volume of a storage or distribution medium does not bring the
|
||||
other work under the scope of this License.
|
||||
In addition, mere aggregation of another work not based on the Program
|
||||
with the Program (or with a work based on the Program) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may copy and distribute the Program (or a work based on it,
|
||||
under Section 2) in object code or executable form under the terms
|
||||
of Sections 1 and 2 above provided that you also do one of the
|
||||
following:
|
||||
under Section 2) in object code or executable form under the terms of
|
||||
Sections 1 and 2 above provided that you also do one of the following:
|
||||
|
||||
a. Accompany it with the complete corresponding machine-readable
|
||||
source code, which must be distributed under the terms of
|
||||
Sections 1 and 2 above on a medium customarily used for
|
||||
software interchange; or,
|
||||
a) Accompany it with the complete corresponding machine-readable
|
||||
source code, which must be distributed under the terms of Sections
|
||||
1 and 2 above on a medium customarily used for software interchange; or,
|
||||
|
||||
b. Accompany it with a written offer, valid for at least three
|
||||
years, to give any third-party, for a charge no more than your
|
||||
cost of physically performing source distribution, a complete
|
||||
machine-readable copy of the corresponding source code, to be
|
||||
distributed under the terms of Sections 1 and 2 above on a
|
||||
medium customarily used for software interchange; or,
|
||||
b) Accompany it with a written offer, valid for at least three
|
||||
years, to give any third party, for a charge no more than your
|
||||
cost of physically performing source distribution, a complete
|
||||
machine-readable copy of the corresponding source code, to be
|
||||
distributed under the terms of Sections 1 and 2 above on a medium
|
||||
customarily used for software interchange; or,
|
||||
|
||||
c. Accompany it with the information you received as to the offer
|
||||
to distribute corresponding source code. (This alternative is
|
||||
allowed only for noncommercial distribution and only if you
|
||||
received the program in object code or executable form with
|
||||
such an offer, in accord with Subsection b above.)
|
||||
c) Accompany it with the information you received as to the offer
|
||||
to distribute corresponding source code. (This alternative is
|
||||
allowed only for noncommercial distribution and only if you
|
||||
received the program in object code or executable form with such
|
||||
an offer, in accord with Subsection b above.)
|
||||
|
||||
The source code for a work means the preferred form of the work for
|
||||
making modifications to it. For an executable work, complete
|
||||
source code means all the source code for all modules it contains,
|
||||
plus any associated interface definition files, plus the scripts
|
||||
used to control compilation and installation of the executable.
|
||||
However, as a special exception, the source code distributed need
|
||||
not include anything that is normally distributed (in either
|
||||
source or binary form) with the major components (compiler,
|
||||
kernel, and so on) of the operating system on which the executable
|
||||
runs, unless that component itself accompanies the executable.
|
||||
The source code for a work means the preferred form of the work for
|
||||
making modifications to it. For an executable work, complete source
|
||||
code means all the source code for all modules it contains, plus any
|
||||
associated interface definition files, plus the scripts used to
|
||||
control compilation and installation of the executable. However, as a
|
||||
special exception, the source code distributed need not include
|
||||
anything that is normally distributed (in either source or binary
|
||||
form) with the major components (compiler, kernel, and so on) of the
|
||||
operating system on which the executable runs, unless that component
|
||||
itself accompanies the executable.
|
||||
|
||||
If distribution of executable or object code is made by offering
|
||||
access to copy from a designated place, then offering equivalent
|
||||
access to copy the source code from the same place counts as
|
||||
distribution of the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
If distribution of executable or object code is made by offering
|
||||
access to copy from a designated place, then offering equivalent
|
||||
access to copy the source code from the same place counts as
|
||||
distribution of the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
4. You may not copy, modify, sublicense, or distribute the Program
|
||||
except as expressly provided under this License. Any attempt
|
||||
otherwise to copy, modify, sublicense or distribute the Program is
|
||||
void, and will automatically terminate your rights under this
|
||||
License. However, parties who have received copies, or rights,
|
||||
from you under this License will not have their licenses
|
||||
terminated so long as such parties remain in full compliance.
|
||||
except as expressly provided under this License. Any attempt
|
||||
otherwise to copy, modify, sublicense or distribute the Program is
|
||||
void, and will automatically terminate your rights under this License.
|
||||
However, parties who have received copies, or rights, from you under
|
||||
this License will not have their licenses terminated so long as such
|
||||
parties remain in full compliance.
|
||||
|
||||
5. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify
|
||||
or distribute the Program or its derivative works. These actions
|
||||
are prohibited by law if you do not accept this License.
|
||||
Therefore, by modifying or distributing the Program (or any work
|
||||
based on the Program), you indicate your acceptance of this
|
||||
License to do so, and all its terms and conditions for copying,
|
||||
distributing or modifying the Program or works based on it.
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Program or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Program (or any work based on the
|
||||
Program), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Program or works based on it.
|
||||
|
||||
6. Each time you redistribute the Program (or any work based on the
|
||||
Program), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute or modify the Program
|
||||
subject to these terms and conditions. You may not impose any
|
||||
further restrictions on the recipients' exercise of the rights
|
||||
granted herein. You are not responsible for enforcing compliance
|
||||
by third parties to this License.
|
||||
Program), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute or modify the Program subject to
|
||||
these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties to
|
||||
this License.
|
||||
|
||||
7. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent
|
||||
issues), conditions are imposed on you (whether by court order,
|
||||
agreement or otherwise) that contradict the conditions of this
|
||||
License, they do not excuse you from the conditions of this
|
||||
License. If you cannot distribute so as to satisfy simultaneously
|
||||
your obligations under this License and any other pertinent
|
||||
obligations, then as a consequence you may not distribute the
|
||||
Program at all. For example, if a patent license would not permit
|
||||
royalty-free redistribution of the Program by all those who
|
||||
receive copies directly or indirectly through you, then the only
|
||||
way you could satisfy both it and this License would be to refrain
|
||||
entirely from distribution of the Program.
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Program at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Program by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Program.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable
|
||||
under any particular circumstance, the balance of the section is
|
||||
intended to apply and the section as a whole is intended to apply
|
||||
in other circumstances.
|
||||
If any portion of this section is held invalid or unenforceable under
|
||||
any particular circumstance, the balance of the section is intended to
|
||||
apply and the section as a whole is intended to apply in other
|
||||
circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of
|
||||
any such claims; this section has the sole purpose of protecting
|
||||
the integrity of the free software distribution system, which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is
|
||||
willing to distribute software through any other system and a
|
||||
licensee cannot impose that choice.
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system, which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed
|
||||
to be a consequence of the rest of this License.
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
8. If the distribution and/or use of the Program is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces,
|
||||
the original copyright holder who places the Program under this
|
||||
License may add an explicit geographical distribution limitation
|
||||
excluding those countries, so that distribution is permitted only
|
||||
in or among countries not thus excluded. In such case, this
|
||||
License incorporates the limitation as if written in the body of
|
||||
this License.
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Program under this License
|
||||
may add an explicit geographical distribution limitation excluding
|
||||
those countries, so that distribution is permitted only in or among
|
||||
countries not thus excluded. In such case, this License incorporates
|
||||
the limitation as if written in the body of this License.
|
||||
|
||||
9. The Free Software Foundation may publish revised and/or new
|
||||
versions of the General Public License from time to time. Such
|
||||
new versions will be similar in spirit to the present version, but
|
||||
may differ in detail to address new problems or concerns.
|
||||
9. The Free Software Foundation may publish revised and/or new versions
|
||||
of the General Public License from time to time. Such new versions will
|
||||
be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Program specifies a version number of this License which applies
|
||||
to it and "any later version", you have the option of following
|
||||
the terms and conditions either of that version or of any later
|
||||
version published by the Free Software Foundation. If the Program
|
||||
does not specify a version number of this License, you may choose
|
||||
any version ever published by the Free Software Foundation.
|
||||
Each version is given a distinguishing version number. If the Program
|
||||
specifies a version number of this License which applies to it and "any
|
||||
later version", you have the option of following the terms and conditions
|
||||
either of that version or of any later version published by the Free
|
||||
Software Foundation. If the Program does not specify a version number of
|
||||
this License, you may choose any version ever published by the Free Software
|
||||
Foundation.
|
||||
|
||||
10. If you wish to incorporate parts of the Program into other free
|
||||
programs whose distribution conditions are different, write to the
|
||||
author to ask for permission. For software which is copyrighted
|
||||
by the Free Software Foundation, write to the Free Software
|
||||
Foundation; we sometimes make exceptions for this. Our decision
|
||||
will be guided by the two goals of preserving the free status of
|
||||
all derivatives of our free software and of promoting the sharing
|
||||
and reuse of software generally.
|
||||
10. If you wish to incorporate parts of the Program into other free
|
||||
programs whose distribution conditions are different, write to the author
|
||||
to ask for permission. For software which is copyrighted by the Free
|
||||
Software Foundation, write to the Free Software Foundation; we sometimes
|
||||
make exceptions for this. Our decision will be guided by the two goals
|
||||
of preserving the free status of all derivatives of our free software and
|
||||
of promoting the sharing and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO
|
||||
WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE
|
||||
LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT
|
||||
WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT
|
||||
NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE
|
||||
QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
|
||||
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY
|
||||
SERVICING, REPAIR OR CORRECTION.
|
||||
NO WARRANTY
|
||||
|
||||
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
|
||||
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY
|
||||
MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE
|
||||
LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL,
|
||||
INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR
|
||||
INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU
|
||||
OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY
|
||||
OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN
|
||||
ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
|
||||
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
|
||||
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
|
||||
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
|
||||
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
|
||||
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
|
||||
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
|
||||
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
|
||||
REPAIR OR CORRECTION.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
How to Apply These Terms to Your New Programs
|
||||
=============================================
|
||||
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
|
||||
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
|
||||
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
|
||||
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
|
||||
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
|
||||
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
|
||||
POSSIBILITY OF SUCH DAMAGES.
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these
|
||||
terms.
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest to
|
||||
attach them to the start of each source file to most effectively convey
|
||||
the exclusion of warranty; and each file should have at least the
|
||||
"copyright" line and a pointer to where the full notice is found.
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
convey the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
ONE LINE TO GIVE THE PROGRAM'S NAME AND A BRIEF IDEA OF WHAT IT DOES.
|
||||
Copyright (C) YYYY NAME OF AUTHOR
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
You should have received a copy of the GNU General Public License along
|
||||
with this program; if not, write to the Free Software Foundation, Inc.,
|
||||
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program is interactive, make it output a short notice like this
|
||||
when it starts in an interactive mode:
|
||||
|
||||
Gnomovision version 69, Copyright (C) 19YY NAME OF AUTHOR
|
||||
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
Gnomovision version 69, Copyright (C) year name of author
|
||||
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the
|
||||
appropriate parts of the General Public License. Of course, the
|
||||
commands you use may be called something other than `show w' and `show
|
||||
c'; they could even be mouse-clicks or menu items--whatever suits your
|
||||
program.
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, the commands you use may
|
||||
be called something other than `show w' and `show c'; they could even be
|
||||
mouse-clicks or menu items--whatever suits your program.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or your
|
||||
school, if any, to sign a "copyright disclaimer" for the program, if
|
||||
necessary. Here is a sample; alter the names:
|
||||
|
||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
|
||||
`Gnomovision' (which makes passes at compilers) written by James Hacker.
|
||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
|
||||
`Gnomovision' (which makes passes at compilers) written by James Hacker.
|
||||
|
||||
SIGNATURE OF TY COON, 1 April 1989
|
||||
Ty Coon, President of Vice
|
||||
|
||||
This General Public License does not permit incorporating your program
|
||||
into proprietary programs. If your program is a subroutine library,
|
||||
you may consider it more useful to permit linking proprietary
|
||||
applications with the library. If this is what you want to do, use the
|
||||
GNU Library General Public License instead of this License.
|
||||
<signature of Ty Coon>, 1 April 1989
|
||||
Ty Coon, President of Vice
|
||||
|
||||
This General Public License does not permit incorporating your program into
|
||||
proprietary programs. If your program is a subroutine library, you may
|
||||
consider it more useful to permit linking proprietary applications with the
|
||||
library. If this is what you want to do, use the GNU Lesser General
|
||||
Public License instead of this License.
|
||||
|
|
56
README
56
README
|
@ -1,6 +1,58 @@
|
|||
DO NOT TRANSLATE OR LOCALIZE
|
||||
This is a release of MySQL, a dual-license SQL database server.
|
||||
MySQL is brought to you by the MySQL team at Oracle Corporation.
|
||||
|
||||
***************************************************************************
|
||||
************************************************************
|
||||
LICENSE
|
||||
************************************************************
|
||||
License information and use restrictions of this software can
|
||||
be found in these files:
|
||||
- For GPL (free) distributions, see the COPYING file and
|
||||
the EXCEPTIONS-CLIENT file.
|
||||
- For commercial distributions, see the LICENSE.mysql file.
|
||||
|
||||
GPLv2 Disclaimer
|
||||
For the avoidance of doubt, except that if any license choice
|
||||
other than GPL or LGPL is available it will apply instead, Oracle
|
||||
elects to use only the General Public License version 2 (GPLv2)
|
||||
at this time for any software where a choice of GPL license versions
|
||||
is made available with the language indicating that GPLv2 or any
|
||||
later version may be used, or where a choice of which version of
|
||||
the GPL is applied is otherwise unspecified.
|
||||
|
||||
************************************************************
|
||||
FURTHER INFORMATION
|
||||
************************************************************
|
||||
For further information about MySQL or additional documentation, see:
|
||||
- The latest information about MySQL: http://dev.mysql.com/
|
||||
- The current MySQL documentation: http://dev.mysql.com/doc/
|
||||
|
||||
Some manual sections of special interest:
|
||||
- If you are migrating from an older version of MySQL, please read
|
||||
the "Upgrading from..." section first!
|
||||
- To see what MySQL can do, take a look at the features section.
|
||||
- For installation instructions, see the Installing and Upgrading
|
||||
chapter.
|
||||
- For the new features/bugfix history, see the Change History appendix.
|
||||
- For the currently known bugs/misfeatures (known errors) see the
|
||||
Problems and Common Errors appendix.
|
||||
- For a list of developers and other contributors, see the Credits
|
||||
appendix.
|
||||
|
||||
A local copy of the MySQL Reference Manual can be found in the Docs
|
||||
directory in GNU Info format. You can also browse the manual online or
|
||||
download it in any of several formats at the URL given earlier in this
|
||||
file.
|
||||
|
||||
************************************************************
|
||||
IMPORTANT:
|
||||
|
||||
Bug or error reports should be sent to http://bugs.mysql.com.
|
||||
************************************************************
|
||||
|
||||
|
||||
************************************************************
|
||||
THIRD-PARTY SOFTWARE
|
||||
************************************************************
|
||||
|
||||
%%The following software may be included in this product:
|
||||
FindGTest.cmake (part of CMake 2.8.0)
|
||||
|
|
|
@ -27,7 +27,7 @@ AC_PREREQ(2.59)
|
|||
# Remember to also update version.c in ndb.
|
||||
# When changing major version number please also check switch statement
|
||||
# in client/mysqlbinlog.cc:check_master_version().
|
||||
AC_INIT([MySQL Server], [5.5.99-m3], [], [mysql])
|
||||
AC_INIT([MySQL Server], [5.6.99-m4], [], [mysql])
|
||||
AC_CONFIG_SRCDIR([sql/mysqld.cc])
|
||||
AC_CANONICAL_SYSTEM
|
||||
# USTAR format gives us the possibility to store longer path names in
|
||||
|
|
|
@ -38,6 +38,7 @@ extern "C" {
|
|||
|
||||
#define my_wc_t ulong
|
||||
|
||||
#define MY_CS_REPLACEMENT_CHARACTER 0xFFFD
|
||||
|
||||
/*
|
||||
On i386 we store Unicode->CS conversion tables for
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
binlog.binlog_multi_engine # joro : NDB tests marked as experimental as agreed with bochklin
|
||||
|
||||
funcs_1.charset_collation_1 # depends on compile-time decisions
|
||||
funcs_1.myisam_views @solaris # Bug#50595 2010-03-05 alik funcs_1.myisam_views takes longer time on 6.0 branch than 5.1 branch
|
||||
|
||||
main.information_schema # Bug#47449 2009-09-19 alik main.information_schema and innodb.innodb_information_schema fail sporadically
|
||||
main.lock_multi_bug38499 # Bug#47448 2009-09-19 alik main.lock_multi_bug38499 times out sporadically
|
||||
|
|
1858
mysql-test/include/ctype_utf8mb4.inc
Normal file
1858
mysql-test/include/ctype_utf8mb4.inc
Normal file
File diff suppressed because it is too large
Load diff
|
@ -109,6 +109,7 @@ our $glob_use_embedded_server= 0;
|
|||
our @glob_test_mode;
|
||||
|
||||
our $glob_basedir;
|
||||
our $glob_bindir;
|
||||
|
||||
our $path_charsetsdir;
|
||||
our $path_client_bindir;
|
||||
|
@ -157,7 +158,6 @@ our $exe_mysqltest;
|
|||
our $exe_ndbd;
|
||||
our $exe_ndb_mgmd;
|
||||
our $exe_slave_mysqld;
|
||||
our $exe_im;
|
||||
our $exe_my_print_defaults;
|
||||
our $exe_perror;
|
||||
our $lib_udf_example;
|
||||
|
@ -720,13 +720,21 @@ sub command_line_setup () {
|
|||
$glob_mysql_test_dir= `cygpath -m "$glob_mysql_test_dir"`;
|
||||
chomp($glob_mysql_test_dir);
|
||||
}
|
||||
$default_vardir= "$glob_mysql_test_dir/var";
|
||||
if (defined $ENV{MTR_BINDIR})
|
||||
{
|
||||
$default_vardir= "$ENV{MTR_BINDIR}/mysql-test/var";
|
||||
}
|
||||
else
|
||||
{
|
||||
$default_vardir= "$glob_mysql_test_dir/var";
|
||||
}
|
||||
|
||||
# In most cases, the base directory we find everything relative to,
|
||||
# is the parent directory of the "mysql-test" directory. For source
|
||||
# distributions, TAR binary distributions and some other packages.
|
||||
$glob_basedir= dirname($glob_mysql_test_dir);
|
||||
|
||||
$glob_bindir= $ENV{'MTR_BINDIR'} || $glob_basedir;
|
||||
# In the RPM case, binaries and libraries are installed in the
|
||||
# default system locations, instead of having our own private base
|
||||
# directory. And we install "/usr/share/mysql-test". Moving up one
|
||||
|
@ -792,36 +800,37 @@ sub command_line_setup () {
|
|||
}
|
||||
else
|
||||
{
|
||||
$path_client_bindir= mtr_path_exists("$glob_basedir/client_release",
|
||||
"$glob_basedir/client_debug",
|
||||
$path_client_bindir= mtr_path_exists("$glob_bindir/client_release",
|
||||
"$glob_bindir/client_debug",
|
||||
vs_config_dirs('client', ''),
|
||||
"$glob_basedir/client",
|
||||
"$glob_basedir/bin");
|
||||
"$glob_bindir/client",
|
||||
"$glob_bindir/bin");
|
||||
}
|
||||
|
||||
# Look for language files and charsetsdir, use same share
|
||||
$path_share= mtr_path_exists("$glob_basedir/share/mysql",
|
||||
"$glob_basedir/sql/share",
|
||||
"$glob_basedir/share");
|
||||
$path_share= mtr_path_exists("$glob_bindir/share/mysql",
|
||||
"$glob_bindir/sql/share",
|
||||
"$glob_bindir/share");
|
||||
|
||||
$path_language= mtr_path_exists("$path_share");
|
||||
$path_charsetsdir= mtr_path_exists("$path_share/charsets");
|
||||
|
||||
$path_charsetsdir = mtr_path_exists("$glob_basedir/share/mysql/charsets",
|
||||
"$glob_basedir/sql/share/charsets",
|
||||
"$glob_basedir/share/charsets");
|
||||
|
||||
if (!$opt_extern)
|
||||
{
|
||||
$exe_mysqld= mtr_exe_exists (vs_config_dirs('sql', 'mysqld'),
|
||||
vs_config_dirs('sql', 'mysqld-debug'),
|
||||
"$glob_basedir/sql/mysqld",
|
||||
"$glob_bindir/sql/mysqld",
|
||||
"$path_client_bindir/mysqld-max-nt",
|
||||
"$path_client_bindir/mysqld-max",
|
||||
"$path_client_bindir/mysqld-nt",
|
||||
"$path_client_bindir/mysqld",
|
||||
"$path_client_bindir/mysqld-debug",
|
||||
"$path_client_bindir/mysqld-max",
|
||||
"$glob_basedir/libexec/mysqld",
|
||||
"$glob_basedir/bin/mysqld",
|
||||
"$glob_basedir/sbin/mysqld");
|
||||
"$glob_bindir/libexec/mysqld",
|
||||
"$glob_bindir/bin/mysqld",
|
||||
"$glob_bindir/sbin/mysqld");
|
||||
|
||||
# Use the mysqld found above to find out what features are available
|
||||
collect_mysqld_features();
|
||||
|
@ -1563,37 +1572,24 @@ sub collect_mysqld_features_from_running_server ()
|
|||
}
|
||||
}
|
||||
|
||||
sub executable_setup_im () {
|
||||
|
||||
# Look for instance manager binary - mysqlmanager
|
||||
$exe_im=
|
||||
mtr_exe_maybe_exists(
|
||||
"$glob_basedir/server-tools/instance-manager/mysqlmanager",
|
||||
"$glob_basedir/libexec/mysqlmanager",
|
||||
"$glob_basedir/bin/mysqlmanager",
|
||||
"$glob_basedir/sbin/mysqlmanager");
|
||||
|
||||
return ($exe_im eq "");
|
||||
}
|
||||
|
||||
sub executable_setup_ndb () {
|
||||
|
||||
# Look for ndb tols and binaries
|
||||
my $ndb_path= mtr_file_exists("$glob_basedir/ndb",
|
||||
"$glob_basedir/storage/ndb",
|
||||
"$glob_basedir/bin");
|
||||
my $ndb_path= mtr_file_exists("$glob_bindir/ndb",
|
||||
"$glob_bindir/storage/ndb",
|
||||
"$glob_bindir/bin");
|
||||
|
||||
$exe_ndbd=
|
||||
mtr_exe_maybe_exists("$ndb_path/src/kernel/ndbd",
|
||||
"$ndb_path/ndbd",
|
||||
"$glob_basedir/libexec/ndbd");
|
||||
"$glob_bindir/libexec/ndbd");
|
||||
$exe_ndb_mgm=
|
||||
mtr_exe_maybe_exists("$ndb_path/src/mgmclient/ndb_mgm",
|
||||
"$ndb_path/ndb_mgm");
|
||||
$exe_ndb_mgmd=
|
||||
mtr_exe_maybe_exists("$ndb_path/src/mgmsrv/ndb_mgmd",
|
||||
"$ndb_path/ndb_mgmd",
|
||||
"$glob_basedir/libexec/ndb_mgmd");
|
||||
"$glob_bindir/libexec/ndb_mgmd");
|
||||
$exe_ndb_waiter=
|
||||
mtr_exe_maybe_exists("$ndb_path/tools/ndb_waiter",
|
||||
"$ndb_path/ndb_waiter");
|
||||
|
@ -1636,11 +1632,11 @@ sub executable_setup () {
|
|||
$exe_my_print_defaults=
|
||||
mtr_exe_exists(vs_config_dirs('extra', 'my_print_defaults'),
|
||||
"$path_client_bindir/my_print_defaults",
|
||||
"$glob_basedir/extra/my_print_defaults");
|
||||
"$glob_bindir/extra/my_print_defaults");
|
||||
|
||||
# Look for perror
|
||||
$exe_perror= mtr_exe_exists(vs_config_dirs('extra', 'perror'),
|
||||
"$glob_basedir/extra/perror",
|
||||
"$glob_bindir/extra/perror",
|
||||
"$path_client_bindir/perror");
|
||||
|
||||
# Look for the client binaries
|
||||
|
@ -1697,23 +1693,15 @@ sub executable_setup () {
|
|||
}
|
||||
}
|
||||
|
||||
if ( ! $opt_skip_im and executable_setup_im())
|
||||
{
|
||||
mtr_warning("Could not find all required instance manager binaries, " .
|
||||
"all im tests will fail, use --skip-im to " .
|
||||
"continue without instance manager");
|
||||
$instance_manager->{"executable_setup_failed"}= 1;
|
||||
}
|
||||
|
||||
# Look for the udf_example library
|
||||
$lib_udf_example=
|
||||
mtr_file_exists(vs_config_dirs('sql', 'udf_example.dll'),
|
||||
"$glob_basedir/sql/.libs/udf_example.so",);
|
||||
"$glob_bindir/sql/.libs/udf_example.so",);
|
||||
|
||||
# Look for the ha_example library
|
||||
$lib_example_plugin=
|
||||
mtr_file_exists(vs_config_dirs('storage/example', 'ha_example.dll'),
|
||||
"$glob_basedir/storage/example/.libs/ha_example.so",);
|
||||
"$glob_bindir/storage/example/.libs/ha_example.so",);
|
||||
|
||||
}
|
||||
|
||||
|
@ -1722,7 +1710,7 @@ sub executable_setup () {
|
|||
{
|
||||
$exe_mysqltest=
|
||||
mtr_exe_exists(vs_config_dirs('libmysqld/examples','mysqltest_embedded'),
|
||||
"$glob_basedir/libmysqld/examples/mysqltest_embedded",
|
||||
"$glob_bindir/libmysqld/examples/mysqltest_embedded",
|
||||
"$path_client_bindir/mysqltest_embedded");
|
||||
}
|
||||
else
|
||||
|
@ -1737,21 +1725,21 @@ sub executable_setup () {
|
|||
$exe_mysql_client_test=
|
||||
mtr_exe_maybe_exists(
|
||||
vs_config_dirs('libmysqld/examples', 'mysql_client_test_embedded'),
|
||||
"$glob_basedir/libmysqld/examples/mysql_client_test_embedded");
|
||||
"$glob_bindir/libmysqld/examples/mysql_client_test_embedded");
|
||||
}
|
||||
else
|
||||
{
|
||||
$exe_mysql_client_test=
|
||||
mtr_exe_maybe_exists(vs_config_dirs('tests', 'mysql_client_test'),
|
||||
"$glob_basedir/tests/mysql_client_test",
|
||||
"$glob_basedir/bin/mysql_client_test");
|
||||
"$glob_bindir/tests/mysql_client_test",
|
||||
"$glob_bindir/bin/mysql_client_test");
|
||||
}
|
||||
|
||||
# Look for bug25714 executable which may _not_ exist in
|
||||
# some versions, test using it should be skipped
|
||||
$exe_bug25714=
|
||||
mtr_exe_maybe_exists(vs_config_dirs('tests', 'bug25714'),
|
||||
"$glob_basedir/tests/bug25714");
|
||||
"$glob_bindir/tests/bug25714");
|
||||
}
|
||||
|
||||
|
||||
|
@ -1860,13 +1848,13 @@ sub environment_setup () {
|
|||
# are used in favor of the system installed ones
|
||||
if ( $source_dist )
|
||||
{
|
||||
push(@ld_library_paths, "$glob_basedir/libmysql/.libs/",
|
||||
"$glob_basedir/libmysql_r/.libs/",
|
||||
"$glob_basedir/zlib.libs/");
|
||||
push(@ld_library_paths, "$glob_bindir/libmysql/.libs/",
|
||||
"$glob_bindir/libmysql_r/.libs/",
|
||||
"$glob_bindir/zlib.libs/");
|
||||
}
|
||||
else
|
||||
{
|
||||
push(@ld_library_paths, "$glob_basedir/lib");
|
||||
push(@ld_library_paths, "$glob_bindir/lib");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1875,7 +1863,7 @@ sub environment_setup () {
|
|||
# --------------------------------------------------------------------------
|
||||
if ( $glob_ndbcluster_supported )
|
||||
{
|
||||
push(@ld_library_paths, "$glob_basedir/storage/ndb/src/.libs");
|
||||
push(@ld_library_paths, "$glob_bindir/storage/ndb/src/.libs");
|
||||
}
|
||||
|
||||
# --------------------------------------------------------------------------
|
||||
|
@ -1993,7 +1981,6 @@ sub environment_setup () {
|
|||
# ----------------------------------------------------
|
||||
if ( ! $opt_skip_im )
|
||||
{
|
||||
$ENV{'IM_EXE'}= $exe_im;
|
||||
$ENV{'IM_PATH_PID'}= $instance_manager->{path_pid};
|
||||
$ENV{'IM_PATH_ANGEL_PID'}= $instance_manager->{path_angel_pid};
|
||||
$ENV{'IM_PORT'}= $instance_manager->{port};
|
||||
|
@ -2190,14 +2177,14 @@ sub environment_setup () {
|
|||
vs_config_dirs('storage/myisam', 'myisamchk'),
|
||||
vs_config_dirs('myisam', 'myisamchk'),
|
||||
"$path_client_bindir/myisamchk",
|
||||
"$glob_basedir/storage/myisam/myisamchk",
|
||||
"$glob_basedir/myisam/myisamchk"));
|
||||
"$glob_bindir/storage/myisam/myisamchk",
|
||||
"$glob_bindir/myisam/myisamchk"));
|
||||
$ENV{'MYISAMPACK'}= mtr_native_path(mtr_exe_exists(
|
||||
vs_config_dirs('storage/myisam', 'myisampack'),
|
||||
vs_config_dirs('myisam', 'myisampack'),
|
||||
"$path_client_bindir/myisampack",
|
||||
"$glob_basedir/storage/myisam/myisampack",
|
||||
"$glob_basedir/myisam/myisampack"));
|
||||
"$glob_bindir/storage/myisam/myisampack",
|
||||
"$glob_bindir/myisam/myisampack"));
|
||||
|
||||
# ----------------------------------------------------
|
||||
# We are nice and report a bit about our settings
|
||||
|
@ -2548,12 +2535,12 @@ sub vs_config_dirs ($$) {
|
|||
|
||||
if ($opt_vs_config)
|
||||
{
|
||||
return ("$glob_basedir/$path_part/$opt_vs_config/$exe");
|
||||
return ("$glob_bindir/$path_part/$opt_vs_config/$exe");
|
||||
}
|
||||
|
||||
return ("$glob_basedir/$path_part/release/$exe",
|
||||
"$glob_basedir/$path_part/relwithdebinfo/$exe",
|
||||
"$glob_basedir/$path_part/debug/$exe");
|
||||
return ("$glob_bindir/$path_part/release/$exe",
|
||||
"$glob_bindir/$path_part/relwithdebinfo/$exe",
|
||||
"$glob_bindir/$path_part/debug/$exe");
|
||||
}
|
||||
|
||||
##############################################################################
|
||||
|
|
|
@ -2158,6 +2158,10 @@ u_decimal hex(utf8mb4_encoding)
|
|||
INSERT INTO t1 VALUES (1114111, x'f5808080');
|
||||
Warnings:
|
||||
Warning 1366 Incorrect string value: '\xF5\x80\x80\x80' for column 'utf8mb4_encoding' at row 1
|
||||
SELECT character_maximum_length, character_octet_length FROM information_schema.columns WHERE
|
||||
table_name= 't1' AND column_name= 'utf8mb4_encoding';
|
||||
character_maximum_length character_octet_length
|
||||
10 40
|
||||
DROP TABLE IF EXISTS t2;
|
||||
CREATE TABLE t2 (
|
||||
u_decimal int NOT NULL,
|
||||
|
@ -2168,20 +2172,197 @@ INSERT INTO t2 VALUES (65131, x'efb9ab');
|
|||
INSERT INTO t2 VALUES (1114111, x'f48fbfbf');
|
||||
Warnings:
|
||||
Warning 1366 Incorrect string value: '\xF4\x8F\xBF\xBF' for column 'utf8mb3_encoding' at row 1
|
||||
SELECT character_maximum_length, character_octet_length FROM information_schema.columns WHERE
|
||||
table_name= 't2' AND column_name= 'utf8mb3_encoding';
|
||||
character_maximum_length character_octet_length
|
||||
10 30
|
||||
UPDATE t2 SET utf8mb3_encoding= x'f48fbfbd' where u_decimal= 42856;
|
||||
Warnings:
|
||||
Warning 1366 Incorrect string value: '\xF4\x8F\xBF\xBD' for column 'utf8mb3_encoding' at row 1
|
||||
UPDATE t2 SET utf8mb3_encoding= _utf8mb4 x'ea9da8' where u_decimal= 42856;
|
||||
SELECT HEX(CONCAT(utf8mb4_encoding, _utf8 x'ea9da8')) FROM t1;
|
||||
HEX(CONCAT(utf8mb4_encoding, _utf8 x'ea9da8'))
|
||||
F09D8480EA9DA8
|
||||
F09D849EEA9DA8
|
||||
F09D859EEA9DA8
|
||||
F09D878FEA9DA8
|
||||
F09D9C9FEA9DA8
|
||||
F09D9E9FEA9DA8
|
||||
F48FBFBFEA9DA8
|
||||
F3A087AFEA9DA8
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480EA9DA8
|
||||
EFB9ABF09D849EF09D859EF09D859EF09D8480F09D859FEFB9ABEFB9ABF09D85A0EFB9ABEA9DA8
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480EA9DA8
|
||||
EA9DA8
|
||||
SELECT HEX(CONCAT(utf8mb4_encoding, utf8mb3_encoding)) FROM t1,t2;
|
||||
HEX(CONCAT(utf8mb4_encoding, utf8mb3_encoding))
|
||||
F09D8480EA9DA8
|
||||
F09D8480EFB9AB
|
||||
F09D8480
|
||||
F09D849EEA9DA8
|
||||
F09D849EEFB9AB
|
||||
F09D849E
|
||||
F09D859EEA9DA8
|
||||
F09D859EEFB9AB
|
||||
F09D859E
|
||||
F09D878FEA9DA8
|
||||
F09D878FEFB9AB
|
||||
F09D878F
|
||||
F09D9C9FEA9DA8
|
||||
F09D9C9FEFB9AB
|
||||
F09D9C9F
|
||||
F09D9E9FEA9DA8
|
||||
F09D9E9FEFB9AB
|
||||
F09D9E9F
|
||||
F48FBFBFEA9DA8
|
||||
F48FBFBFEFB9AB
|
||||
F48FBFBF
|
||||
F3A087AFEA9DA8
|
||||
F3A087AFEFB9AB
|
||||
F3A087AF
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480EA9DA8
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480EFB9AB
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480
|
||||
EFB9ABF09D849EF09D859EF09D859EF09D8480F09D859FEFB9ABEFB9ABF09D85A0EFB9ABEA9DA8
|
||||
EFB9ABF09D849EF09D859EF09D859EF09D8480F09D859FEFB9ABEFB9ABF09D85A0EFB9ABEFB9AB
|
||||
EFB9ABF09D849EF09D859EF09D859EF09D8480F09D859FEFB9ABEFB9ABF09D85A0EFB9AB
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480EA9DA8
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480EFB9AB
|
||||
F09D849EF09D859EF09D859EF09D8480F09D859FF09D859FF09D859FF09D85A0F09D85A0F09D8480
|
||||
EA9DA8
|
||||
EFB9AB
|
||||
|
||||
SELECT count(*) FROM t1, t2
|
||||
WHERE t1.utf8mb4_encoding > t2.utf8mb3_encoding;
|
||||
count(*)
|
||||
33
|
||||
ALTER TABLE t1 CONVERT TO CHARACTER SET utf8;
|
||||
Warnings:
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x84\x80' for column 'utf8mb4_encoding' at row 1
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x84\x9E' for column 'utf8mb4_encoding' at row 2
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x85\x9E' for column 'utf8mb4_encoding' at row 3
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x87\x8F' for column 'utf8mb4_encoding' at row 4
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x9C\x9F' for column 'utf8mb4_encoding' at row 5
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x9E\x9F' for column 'utf8mb4_encoding' at row 6
|
||||
Warning 1366 Incorrect string value: '\xF4\x8F\xBF\xBF' for column 'utf8mb4_encoding' at row 7
|
||||
Warning 1366 Incorrect string value: '\xF3\xA0\x87\xAF' for column 'utf8mb4_encoding' at row 8
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x84\x9E\xF0\x9D...' for column 'utf8mb4_encoding' at row 9
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x84\x9E\xF0\x9D...' for column 'utf8mb4_encoding' at row 10
|
||||
Warning 1366 Incorrect string value: '\xF0\x9D\x84\x9E\xF0\x9D...' for column 'utf8mb4_encoding' at row 11
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`u_decimal` int(11) NOT NULL,
|
||||
`utf8mb4_encoding` varchar(10) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8
|
||||
SELECT u_decimal,hex(utf8mb4_encoding),utf8mb4_encoding FROM t1;
|
||||
u_decimal hex(utf8mb4_encoding) utf8mb4_encoding
|
||||
119040 3F ?
|
||||
119070 3F ?
|
||||
119134 3F ?
|
||||
119247 3F ?
|
||||
120607 3F ?
|
||||
120735 3F ?
|
||||
1114111 3F ?
|
||||
917999 3F ?
|
||||
119070 3F3F3F3F3F3F3F3F3F3F ??????????
|
||||
65131 EFB9AB3F3F3F3F3FEFB9ABEFB9AB3FEFB9AB ﹫?????﹫﹫?﹫
|
||||
119070 3F3F3F3F3F3F3F3F3F3F ??????????
|
||||
1114111
|
||||
ALTER TABLE t2 CONVERT TO CHARACTER SET utf8mb4;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`u_decimal` int(11) NOT NULL,
|
||||
`utf8mb3_encoding` varchar(10) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4
|
||||
SELECT u_decimal,hex(utf8mb3_encoding) FROM t2;
|
||||
u_decimal hex(utf8mb3_encoding)
|
||||
42856 EA9DA8
|
||||
65131 EFB9AB
|
||||
1114111
|
||||
ALTER TABLE t2 CONVERT TO CHARACTER SET utf8mb3;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`u_decimal` int(11) NOT NULL,
|
||||
`utf8mb3_encoding` varchar(10) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8
|
||||
SELECT u_decimal,hex(utf8mb3_encoding) FROM t2;
|
||||
u_decimal hex(utf8mb3_encoding)
|
||||
42856 EA9DA8
|
||||
65131 EFB9AB
|
||||
1114111
|
||||
ALTER TABLE t1 MODIFY utf8mb4_encoding VARCHAR(10) CHARACTER SET utf8mb3;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`u_decimal` int(11) NOT NULL,
|
||||
`utf8mb4_encoding` varchar(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8
|
||||
SELECT u_decimal,hex(utf8mb4_encoding) FROM t1;
|
||||
u_decimal hex(utf8mb4_encoding)
|
||||
119040 3F
|
||||
119070 3F
|
||||
119134 3F
|
||||
119247 3F
|
||||
120607 3F
|
||||
120735 3F
|
||||
1114111 3F
|
||||
917999 3F
|
||||
119070 3F3F3F3F3F3F3F3F3F3F
|
||||
65131 EFB9AB3F3F3F3F3FEFB9ABEFB9AB3FEFB9AB
|
||||
119070 3F3F3F3F3F3F3F3F3F3F
|
||||
1114111
|
||||
ALTER TABLE t1 MODIFY utf8mb4_encoding VARCHAR(10) CHARACTER SET utf8mb4;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`u_decimal` int(11) NOT NULL,
|
||||
`utf8mb4_encoding` varchar(10) CHARACTER SET utf8mb4 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8
|
||||
SELECT u_decimal,hex(utf8mb4_encoding) FROM t1;
|
||||
u_decimal hex(utf8mb4_encoding)
|
||||
119040 3F
|
||||
119070 3F
|
||||
119134 3F
|
||||
119247 3F
|
||||
120607 3F
|
||||
120735 3F
|
||||
1114111 3F
|
||||
917999 3F
|
||||
119070 3F3F3F3F3F3F3F3F3F3F
|
||||
65131 EFB9AB3F3F3F3F3FEFB9ABEFB9AB3FEFB9AB
|
||||
119070 3F3F3F3F3F3F3F3F3F3F
|
||||
1114111
|
||||
ALTER TABLE t2 MODIFY utf8mb3_encoding VARCHAR(10) CHARACTER SET utf8mb4;
|
||||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`u_decimal` int(11) NOT NULL,
|
||||
`utf8mb3_encoding` varchar(10) CHARACTER SET utf8mb4 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8
|
||||
SELECT u_decimal,hex(utf8mb3_encoding) FROM t2;
|
||||
u_decimal hex(utf8mb3_encoding)
|
||||
42856 EA9DA8
|
||||
65131 EFB9AB
|
||||
1114111
|
||||
DROP TABLE IF EXISTS t3;
|
||||
CREATE TABLE t3 (
|
||||
u_decimal int NOT NULL,
|
||||
utf8mb3_encoding VARCHAR(10) NOT NULL
|
||||
) CHARACTER SET utf8;
|
||||
INSERT INTO t3 SELECT * FROM t1;
|
||||
DROP TABLE IF EXISTS t4;
|
||||
CREATE TABLE t4 (
|
||||
u_decimal int NOT NULL,
|
||||
utf8mb4_encoding VARCHAR(10) NOT NULL
|
||||
) CHARACTER SET utf8mb4;
|
||||
INSERT INTO t3 SELECT * FROM t2;
|
||||
DROP TABLE t1;
|
||||
DROP TABLE t2;
|
||||
DROP TABLE t3;
|
||||
DROP TABLE t4;
|
||||
#
|
||||
# Testing that mixing utf8 and utf8mb4 collations returns utf8mb4
|
||||
#
|
||||
|
@ -2231,6 +2412,62 @@ SELECT CONCAT('a', _utf8 '
|
|||
ERROR HY000: Illegal mix of collations (utf8mb4_general_ci,COERCIBLE) and (utf8_general_ci,COERCIBLE) for operation 'concat'
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug#51675 Server crashes on inserting 4 byte char.
|
||||
# after ALTER TABLE to 'utf8mb4'
|
||||
#
|
||||
SET NAMES utf8;
|
||||
CREATE TABLE t1 (
|
||||
subject varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci,
|
||||
p VARCHAR(15) CHARACTER SET utf8
|
||||
) DEFAULT CHARSET=latin1;
|
||||
ALTER TABLE t1 ADD INDEX (subject);
|
||||
ALTER TABLE t1
|
||||
DEFAULT CHARACTER SET utf8,
|
||||
MODIFY subject varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci,
|
||||
MODIFY p varchar(255) CHARACTER SET utf8;
|
||||
Warnings:
|
||||
Warning 1071 Specified key was too long; max key length is 1000 bytes
|
||||
Warning 1071 Specified key was too long; max key length is 1000 bytes
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`subject` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`p` varchar(255) DEFAULT NULL,
|
||||
KEY `subject` (`subject`(250))
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8
|
||||
INSERT INTO t1(subject) VALUES ('abcd');
|
||||
INSERT INTO t1(subject) VALUES(x'f0909080');
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# Bug #51676 Server crashes on SELECT, ORDER BY on 'utf8mb4' column
|
||||
#
|
||||
SET NAMES utf8mb4;
|
||||
CREATE TABLE t1 (
|
||||
subject varchar(255) character set utf8mb4 collate utf8mb4_unicode_ci,
|
||||
p varchar(15) character set utf8mb4
|
||||
) DEFAULT CHARSET=latin1;
|
||||
INSERT INTO t1(subject) VALUES(0xF0909080);
|
||||
INSERT INTO t1(subject) VALUES(0x616263F0909080646566);
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`subject` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`p` varchar(15) CHARACTER SET utf8mb4 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SELECT * FROM t1 ORDER BY 1;
|
||||
subject p
|
||||
abc𐐀def NULL
|
||||
𐐀 NULL
|
||||
SELECT hex(subject), length(subject), char_length(subject), octet_length(subject) FROM t1 ORDER BY 1;
|
||||
hex(subject) length(subject) char_length(subject) octet_length(subject)
|
||||
616263F0909080646566 10 7 10
|
||||
F0909080 4 1 4
|
||||
SELECT subject FROM t1 ORDER BY 1;
|
||||
subject
|
||||
abc𐐀def
|
||||
𐐀
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# End of 5.5 tests
|
||||
#
|
||||
#
|
||||
|
|
2260
mysql-test/r/ctype_utf8mb4_heap.result
Normal file
2260
mysql-test/r/ctype_utf8mb4_heap.result
Normal file
File diff suppressed because it is too large
Load diff
2407
mysql-test/r/ctype_utf8mb4_innodb.result
Normal file
2407
mysql-test/r/ctype_utf8mb4_innodb.result
Normal file
File diff suppressed because it is too large
Load diff
2407
mysql-test/r/ctype_utf8mb4_myisam.result
Normal file
2407
mysql-test/r/ctype_utf8mb4_myisam.result
Normal file
File diff suppressed because it is too large
Load diff
1876
mysql-test/r/ctype_utf8mb4_ndb.result
Normal file
1876
mysql-test/r/ctype_utf8mb4_ndb.result
Normal file
File diff suppressed because it is too large
Load diff
153
mysql-test/suite/perfschema/r/pfs_upgrade.result
Normal file
153
mysql-test/suite/perfschema/r/pfs_upgrade.result
Normal file
|
@ -0,0 +1,153 @@
|
|||
drop table if exists test.user_table;
|
||||
drop procedure if exists test.user_proc;
|
||||
drop function if exists test.user_func;
|
||||
drop event if exists test.user_event;
|
||||
"Testing mysql_upgrade with TABLE performance_schema.user_table"
|
||||
create table test.user_table(a int);
|
||||
use performance_schema;
|
||||
show tables like "user_table";
|
||||
Tables_in_performance_schema (user_table)
|
||||
user_table
|
||||
ERROR 1644 (HY000) at line 178: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 203: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 233: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 247: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 281: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 302: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 323: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 340: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 379: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 396: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 414: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 431: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 449: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 465: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 502: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 518: Table 'SETUP_TIMERS' already exists
|
||||
FATAL ERROR: Upgrade failed
|
||||
show tables like "user_table";
|
||||
Tables_in_performance_schema (user_table)
|
||||
user_table
|
||||
use test;
|
||||
drop table test.user_table;
|
||||
"Testing mysql_upgrade with VIEW performance_schema.user_view"
|
||||
create view test.user_view as select "Not supposed to be here";
|
||||
use performance_schema;
|
||||
show tables like "user_view";
|
||||
Tables_in_performance_schema (user_view)
|
||||
user_view
|
||||
ERROR 1644 (HY000) at line 178: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 203: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 233: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 247: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 281: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 302: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 323: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 340: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 379: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 396: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 414: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 431: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 449: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 465: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 502: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 518: Table 'SETUP_TIMERS' already exists
|
||||
FATAL ERROR: Upgrade failed
|
||||
show tables like "user_view";
|
||||
Tables_in_performance_schema (user_view)
|
||||
user_view
|
||||
use test;
|
||||
drop view test.user_view;
|
||||
"Testing mysql_upgrade with PROCEDURE performance_schema.user_proc"
|
||||
create procedure test.user_proc()
|
||||
select "Not supposed to be here";
|
||||
update mysql.proc set db='performance_schema' where name='user_proc';
|
||||
ERROR 1644 (HY000) at line 178: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 203: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 233: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 247: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 281: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 302: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 323: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 340: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 379: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 396: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 414: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 431: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 449: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 465: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 502: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 518: Table 'SETUP_TIMERS' already exists
|
||||
FATAL ERROR: Upgrade failed
|
||||
select name from mysql.proc where db='performance_schema';
|
||||
name
|
||||
user_proc
|
||||
update mysql.proc set db='test' where name='user_proc';
|
||||
drop procedure test.user_proc;
|
||||
"Testing mysql_upgrade with FUNCTION performance_schema.user_func"
|
||||
create function test.user_func() returns integer
|
||||
return 0;
|
||||
update mysql.proc set db='performance_schema' where name='user_func';
|
||||
ERROR 1644 (HY000) at line 178: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 203: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 233: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 247: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 281: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 302: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 323: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 340: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 379: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 396: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 414: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 431: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 449: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 465: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 502: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 518: Table 'SETUP_TIMERS' already exists
|
||||
FATAL ERROR: Upgrade failed
|
||||
select name from mysql.proc where db='performance_schema';
|
||||
name
|
||||
user_func
|
||||
update mysql.proc set db='test' where name='user_func';
|
||||
drop function test.user_func;
|
||||
"Testing mysql_upgrade with EVENT performance_schema.user_event"
|
||||
create event test.user_event on schedule every 1 day do
|
||||
select "not supposed to be here";
|
||||
update mysql.event set db='performance_schema' where name='user_event';
|
||||
ERROR 1644 (HY000) at line 178: Unexpected content found in the performance_schema database.
|
||||
ERROR 1050 (42S01) at line 203: Table 'COND_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 233: Table 'EVENTS_WAITS_CURRENT' already exists
|
||||
ERROR 1050 (42S01) at line 247: Table 'EVENTS_WAITS_HISTORY' already exists
|
||||
ERROR 1050 (42S01) at line 261: Table 'EVENTS_WAITS_HISTORY_LONG' already exists
|
||||
ERROR 1050 (42S01) at line 281: Table 'EVENTS_WAITS_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 302: Table 'EVENTS_WAITS_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 323: Table 'EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 340: Table 'FILE_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 359: Table 'FILE_SUMMARY_BY_EVENT_NAME' already exists
|
||||
ERROR 1050 (42S01) at line 379: Table 'FILE_SUMMARY_BY_INSTANCE' already exists
|
||||
ERROR 1050 (42S01) at line 396: Table 'MUTEX_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 414: Table 'PERFORMANCE_TIMERS' already exists
|
||||
ERROR 1050 (42S01) at line 431: Table 'PROCESSLIST' already exists
|
||||
ERROR 1050 (42S01) at line 449: Table 'RWLOCK_INSTANCES' already exists
|
||||
ERROR 1050 (42S01) at line 465: Table 'SETUP_CONSUMERS' already exists
|
||||
ERROR 1050 (42S01) at line 482: Table 'SETUP_INSTRUMENTS' already exists
|
||||
ERROR 1050 (42S01) at line 502: Table 'SETUP_OBJECTS' already exists
|
||||
ERROR 1050 (42S01) at line 518: Table 'SETUP_TIMERS' already exists
|
||||
FATAL ERROR: Upgrade failed
|
||||
select name from mysql.event where db='performance_schema';
|
||||
name
|
||||
user_event
|
||||
update mysql.event set db='test' where name='user_event';
|
||||
drop event test.user_event;
|
137
mysql-test/suite/perfschema/t/pfs_upgrade.test
Normal file
137
mysql-test/suite/perfschema/t/pfs_upgrade.test
Normal file
|
@ -0,0 +1,137 @@
|
|||
# Copyright (C) 2010 Oracle and/or its affiliates. All rights reserved.
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; version 2 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
# Tests for PERFORMANCE_SCHEMA
|
||||
# Make sure mysql_upgrade does not destroy data in a 'performance_schema'
|
||||
# database.
|
||||
#
|
||||
|
||||
--source include/not_embedded.inc
|
||||
--source include/have_perfschema.inc
|
||||
|
||||
--disable_warnings
|
||||
drop table if exists test.user_table;
|
||||
drop procedure if exists test.user_proc;
|
||||
drop function if exists test.user_func;
|
||||
drop event if exists test.user_event;
|
||||
--enable_warnings
|
||||
|
||||
--echo "Testing mysql_upgrade with TABLE performance_schema.user_table"
|
||||
|
||||
create table test.user_table(a int);
|
||||
|
||||
let $MYSQLD_DATADIR= `SELECT @@datadir`;
|
||||
--copy_file $MYSQLD_DATADIR/test/user_table.frm $MYSQLD_DATADIR/performance_schema/user_table.frm
|
||||
|
||||
# Make sure the table is visible
|
||||
use performance_schema;
|
||||
show tables like "user_table";
|
||||
|
||||
--error 1
|
||||
--exec $MYSQL_UPGRADE --skip-verbose > $MYSQLTEST_VARDIR/tmp/pfs_upgrade.out 2> $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
# Verify that mysql_upgrade complained about the performance_schema
|
||||
--cat_file $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
# Make sure the table is still visible
|
||||
show tables like "user_table";
|
||||
|
||||
use test;
|
||||
|
||||
--remove_file $MYSQLD_DATADIR/performance_schema/user_table.frm
|
||||
drop table test.user_table;
|
||||
|
||||
--echo "Testing mysql_upgrade with VIEW performance_schema.user_view"
|
||||
|
||||
create view test.user_view as select "Not supposed to be here";
|
||||
|
||||
let $MYSQLD_DATADIR= `SELECT @@datadir`;
|
||||
--copy_file $MYSQLD_DATADIR/test/user_view.frm $MYSQLD_DATADIR/performance_schema/user_view.frm
|
||||
|
||||
# Make sure the view is visible
|
||||
use performance_schema;
|
||||
show tables like "user_view";
|
||||
|
||||
--error 1
|
||||
--exec $MYSQL_UPGRADE --skip-verbose > $MYSQLTEST_VARDIR/tmp/pfs_upgrade.out 2> $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
# Verify that mysql_upgrade complained about the performance_schema
|
||||
--cat_file $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
# Make sure the view is still visible
|
||||
show tables like "user_view";
|
||||
|
||||
use test;
|
||||
|
||||
--remove_file $MYSQLD_DATADIR/performance_schema/user_view.frm
|
||||
drop view test.user_view;
|
||||
|
||||
--echo "Testing mysql_upgrade with PROCEDURE performance_schema.user_proc"
|
||||
|
||||
create procedure test.user_proc()
|
||||
select "Not supposed to be here";
|
||||
|
||||
update mysql.proc set db='performance_schema' where name='user_proc';
|
||||
|
||||
--error 1
|
||||
--exec $MYSQL_UPGRADE --skip-verbose > $MYSQLTEST_VARDIR/tmp/pfs_upgrade.out 2> $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
# Verify that mysql_upgrade complained about the performance_schema
|
||||
--cat_file $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
select name from mysql.proc where db='performance_schema';
|
||||
|
||||
update mysql.proc set db='test' where name='user_proc';
|
||||
drop procedure test.user_proc;
|
||||
|
||||
--echo "Testing mysql_upgrade with FUNCTION performance_schema.user_func"
|
||||
|
||||
create function test.user_func() returns integer
|
||||
return 0;
|
||||
|
||||
update mysql.proc set db='performance_schema' where name='user_func';
|
||||
|
||||
--error 1
|
||||
--exec $MYSQL_UPGRADE --skip-verbose > $MYSQLTEST_VARDIR/tmp/pfs_upgrade.out 2> $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
# Verify that mysql_upgrade complained about the performance_schema
|
||||
--cat_file $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
select name from mysql.proc where db='performance_schema';
|
||||
|
||||
update mysql.proc set db='test' where name='user_func';
|
||||
drop function test.user_func;
|
||||
|
||||
--echo "Testing mysql_upgrade with EVENT performance_schema.user_event"
|
||||
|
||||
create event test.user_event on schedule every 1 day do
|
||||
select "not supposed to be here";
|
||||
|
||||
update mysql.event set db='performance_schema' where name='user_event';
|
||||
|
||||
--error 1
|
||||
--exec $MYSQL_UPGRADE --skip-verbose > $MYSQLTEST_VARDIR/tmp/pfs_upgrade.out 2> $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
# Verify that mysql_upgrade complained about the performance_schema
|
||||
--cat_file $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
||||
select name from mysql.event where db='performance_schema';
|
||||
|
||||
update mysql.event set db='test' where name='user_event';
|
||||
drop event test.user_event;
|
||||
|
||||
--remove_file $MYSQLTEST_VARDIR/tmp/pfs_upgrade.out
|
||||
--remove_file $MYSQLTEST_VARDIR/tmp/pfs_upgrade.err
|
||||
|
6
mysql-test/suite/sys_vars/r/log_error_func.result
Normal file
6
mysql-test/suite/sys_vars/r/log_error_func.result
Normal file
|
@ -0,0 +1,6 @@
|
|||
select (@err_log:=variable_value)*0 from information_schema.global_variables where variable_name="log_error";
|
||||
(@err_log:=variable_value)*0
|
||||
0
|
||||
select instr(@err_log, "some_random_name5435413.err")>0;
|
||||
instr(@err_log, "some_random_name5435413.err")>0
|
||||
1
|
6
mysql-test/suite/sys_vars/r/log_error_func2.result
Normal file
6
mysql-test/suite/sys_vars/r/log_error_func2.result
Normal file
|
@ -0,0 +1,6 @@
|
|||
select (@err_log:=variable_value)*0 from information_schema.global_variables where variable_name="log_error";
|
||||
(@err_log:=variable_value)*0
|
||||
0
|
||||
select instr(@err_log, ".err")>0;
|
||||
instr(@err_log, ".err")>0
|
||||
1
|
3
mysql-test/suite/sys_vars/r/log_error_func3.result
Normal file
3
mysql-test/suite/sys_vars/r/log_error_func3.result
Normal file
|
@ -0,0 +1,3 @@
|
|||
select variable_value from information_schema.global_variables where variable_name="log_error";
|
||||
variable_value
|
||||
|
5
mysql-test/suite/sys_vars/t/log_error_func.cnf
Normal file
5
mysql-test/suite/sys_vars/t/log_error_func.cnf
Normal file
|
@ -0,0 +1,5 @@
|
|||
# Use default setting for mysqld processes
|
||||
!include include/default_mysqld.cnf
|
||||
|
||||
[mysqld.1]
|
||||
log-error=some_random_name5435413
|
20
mysql-test/suite/sys_vars/t/log_error_func.test
Normal file
20
mysql-test/suite/sys_vars/t/log_error_func.test
Normal file
|
@ -0,0 +1,20 @@
|
|||
# Test for BUG#51215 "log-error partially works with version 5.5"
|
||||
# when --log-error is used without argument
|
||||
|
||||
# check displayed value. We can check only the base name, the rest
|
||||
# depends on paths, symbolic links, --vardir, etc...
|
||||
select (@err_log:=variable_value)*0 from information_schema.global_variables where variable_name="log_error";
|
||||
select instr(@err_log, "some_random_name5435413.err")>0;
|
||||
|
||||
# Check file's existence. The displayed value may be relative or not.
|
||||
let $err_log=`select @err_log`;
|
||||
let $err_log_relative=`select instr(@err_log, ".")=1`;
|
||||
if ($err_log_relative)
|
||||
{
|
||||
let $MYSQLD_DATADIR= `SELECT @@datadir`;
|
||||
file_exists $MYSQLD_DATADIR/$err_log;
|
||||
}
|
||||
if (!$err_log_relative)
|
||||
{
|
||||
file_exists $err_log;
|
||||
}
|
5
mysql-test/suite/sys_vars/t/log_error_func2.cnf
Normal file
5
mysql-test/suite/sys_vars/t/log_error_func2.cnf
Normal file
|
@ -0,0 +1,5 @@
|
|||
# Use default setting for mysqld processes
|
||||
!include include/default_mysqld.cnf
|
||||
|
||||
[mysqld.1]
|
||||
log-error
|
20
mysql-test/suite/sys_vars/t/log_error_func2.test
Normal file
20
mysql-test/suite/sys_vars/t/log_error_func2.test
Normal file
|
@ -0,0 +1,20 @@
|
|||
# Test for BUG#51215 "log-error partially works with version 5.5"
|
||||
# when --log-error is used without argument
|
||||
|
||||
# check displayed value. We can check only the suffix, because
|
||||
# the rest depends on paths, symbolic links, --vardir, etc...
|
||||
select (@err_log:=variable_value)*0 from information_schema.global_variables where variable_name="log_error";
|
||||
select instr(@err_log, ".err")>0;
|
||||
|
||||
# Check file's existence. The displayed value may be relative or not.
|
||||
let $err_log=`select @err_log`;
|
||||
let $err_log_relative=`select instr(@err_log, ".")=1`;
|
||||
if ($err_log_relative)
|
||||
{
|
||||
let $MYSQLD_DATADIR= `SELECT @@datadir`;
|
||||
file_exists $MYSQLD_DATADIR/$err_log;
|
||||
}
|
||||
if (!$err_log_relative)
|
||||
{
|
||||
file_exists $err_log;
|
||||
}
|
5
mysql-test/suite/sys_vars/t/log_error_func3.test
Normal file
5
mysql-test/suite/sys_vars/t/log_error_func3.test
Normal file
|
@ -0,0 +1,5 @@
|
|||
# Test for BUG#51215 "log-error partially works with version 5.5"
|
||||
# when --log-error is not used
|
||||
|
||||
# check displayed value. Should be empty.
|
||||
select variable_value from information_schema.global_variables where variable_name="log_error";
|
|
@ -1603,6 +1603,8 @@ SELECT u_decimal, hex(utf8mb4_encoding) FROM t1 ORDER BY utf8mb4_encoding COLLAT
|
|||
# First invalid 4 byte value
|
||||
INSERT INTO t1 VALUES (1114111, x'f5808080');
|
||||
|
||||
SELECT character_maximum_length, character_octet_length FROM information_schema.columns WHERE
|
||||
table_name= 't1' AND column_name= 'utf8mb4_encoding';
|
||||
|
||||
--disable_warnings
|
||||
DROP TABLE IF EXISTS t2;
|
||||
|
@ -1618,11 +1620,84 @@ INSERT INTO t2 VALUES (65131, x'efb9ab');
|
|||
# <Plane 16 Private Use, Last> (last 4 byte character)
|
||||
INSERT INTO t2 VALUES (1114111, x'f48fbfbf');
|
||||
|
||||
SELECT character_maximum_length, character_octet_length FROM information_schema.columns WHERE
|
||||
table_name= 't2' AND column_name= 'utf8mb3_encoding';
|
||||
|
||||
# Update a 3-byte char col with a 4-byte char, error
|
||||
UPDATE t2 SET utf8mb3_encoding= x'f48fbfbd' where u_decimal= 42856;
|
||||
|
||||
# Update to a 3-byte char casted to 4-byte, error?
|
||||
UPDATE t2 SET utf8mb3_encoding= _utf8mb4 x'ea9da8' where u_decimal= 42856;
|
||||
|
||||
# Returns utfmb4
|
||||
SELECT HEX(CONCAT(utf8mb4_encoding, _utf8 x'ea9da8')) FROM t1;
|
||||
SELECT HEX(CONCAT(utf8mb4_encoding, utf8mb3_encoding)) FROM t1,t2;
|
||||
|
||||
#--error ER_INVALID_CHARACTER_STRING
|
||||
#SELECT CONCAT(_utf8 utf8mb4_encoding, _utf8 '|') FROM t1;
|
||||
#--error ER_INVALID_CHARACTER_STRING
|
||||
#SELECT CONCAT(_utf8mb3 utf8mb4_encoding, _utf8 '|') FROM t1;
|
||||
|
||||
SELECT count(*) FROM t1, t2
|
||||
WHERE t1.utf8mb4_encoding > t2.utf8mb3_encoding;
|
||||
|
||||
# Alter from 4-byte charset to 3-byte charset, error
|
||||
ALTER TABLE t1 CONVERT TO CHARACTER SET utf8;
|
||||
SHOW CREATE TABLE t1;
|
||||
SELECT u_decimal,hex(utf8mb4_encoding),utf8mb4_encoding FROM t1;
|
||||
|
||||
# Alter table from utf8 to utf8mb4
|
||||
ALTER TABLE t2 CONVERT TO CHARACTER SET utf8mb4;
|
||||
SHOW CREATE TABLE t2;
|
||||
SELECT u_decimal,hex(utf8mb3_encoding) FROM t2;
|
||||
|
||||
# Alter table back from utf8mb4 to utf8
|
||||
ALTER TABLE t2 CONVERT TO CHARACTER SET utf8mb3;
|
||||
SHOW CREATE TABLE t2;
|
||||
SELECT u_decimal,hex(utf8mb3_encoding) FROM t2;
|
||||
|
||||
# ALter of utf8mb4 column to utf8
|
||||
ALTER TABLE t1 MODIFY utf8mb4_encoding VARCHAR(10) CHARACTER SET utf8mb3;
|
||||
SHOW CREATE TABLE t1;
|
||||
SELECT u_decimal,hex(utf8mb4_encoding) FROM t1;
|
||||
|
||||
# ALter of utf8 column to utf8mb4
|
||||
ALTER TABLE t1 MODIFY utf8mb4_encoding VARCHAR(10) CHARACTER SET utf8mb4;
|
||||
SHOW CREATE TABLE t1;
|
||||
SELECT u_decimal,hex(utf8mb4_encoding) FROM t1;
|
||||
|
||||
# ALter of utf8 column to utf8mb4
|
||||
ALTER TABLE t2 MODIFY utf8mb3_encoding VARCHAR(10) CHARACTER SET utf8mb4;
|
||||
SHOW CREATE TABLE t2;
|
||||
SELECT u_decimal,hex(utf8mb3_encoding) FROM t2;
|
||||
|
||||
--disable_warnings
|
||||
DROP TABLE IF EXISTS t3;
|
||||
--enable_warnings
|
||||
CREATE TABLE t3 (
|
||||
u_decimal int NOT NULL,
|
||||
utf8mb3_encoding VARCHAR(10) NOT NULL
|
||||
) CHARACTER SET utf8;
|
||||
|
||||
# Insert select utf8mb4 (4-byte) into utf8 (3-byte), error
|
||||
#--error ER_INVALID_CHARACTER_STRING
|
||||
INSERT INTO t3 SELECT * FROM t1;
|
||||
|
||||
--disable_warnings
|
||||
DROP TABLE IF EXISTS t4;
|
||||
--enable_warnings
|
||||
CREATE TABLE t4 (
|
||||
u_decimal int NOT NULL,
|
||||
utf8mb4_encoding VARCHAR(10) NOT NULL
|
||||
) CHARACTER SET utf8mb4;
|
||||
|
||||
# Insert select utf8 (3-byte) into utf8mb4 (4-byte)
|
||||
INSERT INTO t3 SELECT * FROM t2;
|
||||
|
||||
DROP TABLE t1;
|
||||
DROP TABLE t2;
|
||||
DROP TABLE t3;
|
||||
DROP TABLE t4;
|
||||
|
||||
--echo #
|
||||
--echo # Testing that mixing utf8 and utf8mb4 collations returns utf8mb4
|
||||
|
@ -1662,6 +1737,51 @@ SELECT CONCAT(utf8mb4, _utf8 '
|
|||
SELECT CONCAT('a', _utf8 '¿') FROM t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
|
||||
--echo #
|
||||
--echo # Bug#51675 Server crashes on inserting 4 byte char.
|
||||
--echo # after ALTER TABLE to 'utf8mb4'
|
||||
--echo #
|
||||
SET NAMES utf8;
|
||||
CREATE TABLE t1 (
|
||||
subject varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci,
|
||||
p VARCHAR(15) CHARACTER SET utf8
|
||||
) DEFAULT CHARSET=latin1;
|
||||
|
||||
# Alter old table, add index
|
||||
ALTER TABLE t1 ADD INDEX (subject);
|
||||
|
||||
# Alter old 'utf8' table to new 'utf8mb4'
|
||||
ALTER TABLE t1
|
||||
DEFAULT CHARACTER SET utf8,
|
||||
MODIFY subject varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci,
|
||||
MODIFY p varchar(255) CHARACTER SET utf8;
|
||||
SHOW CREATE TABLE t1;
|
||||
|
||||
INSERT INTO t1(subject) VALUES ('abcd');
|
||||
# Insert 4 byte characters
|
||||
INSERT INTO t1(subject) VALUES(x'f0909080');
|
||||
DROP TABLE t1;
|
||||
|
||||
--echo #
|
||||
--echo # Bug #51676 Server crashes on SELECT, ORDER BY on 'utf8mb4' column
|
||||
--echo #
|
||||
SET NAMES utf8mb4;
|
||||
CREATE TABLE t1 (
|
||||
subject varchar(255) character set utf8mb4 collate utf8mb4_unicode_ci,
|
||||
p varchar(15) character set utf8mb4
|
||||
) DEFAULT CHARSET=latin1;
|
||||
# Insert 4 byte characters
|
||||
# 4byte character
|
||||
INSERT INTO t1(subject) VALUES(0xF0909080);
|
||||
# mix of 3 byte & 4 byte
|
||||
INSERT INTO t1(subject) VALUES(0x616263F0909080646566);
|
||||
SHOW CREATE TABLE t1;
|
||||
SELECT * FROM t1 ORDER BY 1;
|
||||
SELECT hex(subject), length(subject), char_length(subject), octet_length(subject) FROM t1 ORDER BY 1;
|
||||
SELECT subject FROM t1 ORDER BY 1;
|
||||
DROP TABLE t1;
|
||||
|
||||
--echo #
|
||||
--echo # End of 5.5 tests
|
||||
--echo #
|
||||
|
|
6
mysql-test/t/ctype_utf8mb4_heap.test
Normal file
6
mysql-test/t/ctype_utf8mb4_heap.test
Normal file
|
@ -0,0 +1,6 @@
|
|||
--source include/have_utf8mb4.inc
|
||||
|
||||
let $engine= heap;
|
||||
let $is_heap= 1;
|
||||
--source include/ctype_utf8mb4.inc
|
||||
|
6
mysql-test/t/ctype_utf8mb4_innodb.test
Normal file
6
mysql-test/t/ctype_utf8mb4_innodb.test
Normal file
|
@ -0,0 +1,6 @@
|
|||
--source include/have_utf8mb4.inc
|
||||
--source include/have_innodb.inc
|
||||
|
||||
let $engine= InnoDB;
|
||||
--source include/ctype_utf8mb4.inc
|
||||
|
5
mysql-test/t/ctype_utf8mb4_myisam.test
Normal file
5
mysql-test/t/ctype_utf8mb4_myisam.test
Normal file
|
@ -0,0 +1,5 @@
|
|||
--source include/have_utf8mb4.inc
|
||||
|
||||
let $engine= MyISAM;
|
||||
--source include/ctype_utf8mb4.inc
|
||||
|
7
mysql-test/t/ctype_utf8mb4_ndb.test
Normal file
7
mysql-test/t/ctype_utf8mb4_ndb.test
Normal file
|
@ -0,0 +1,7 @@
|
|||
--source include/have_utf8mb4.inc
|
||||
--source include/have_ndb.inc
|
||||
|
||||
let $engine= ndb;
|
||||
let $is_ndb= 1;
|
||||
--source include/ctype_utf8mb4.inc
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
-- Copyright (C) 2008-2009 Sun Microsystems, Inc
|
||||
-- Copyright (C) 2008, 2010 Oracle and/or its affiliates. All rights reserved.
|
||||
--
|
||||
-- This program is free software; you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
|
@ -100,19 +100,93 @@ CREATE TABLE IF NOT EXISTS event ( db char(64) CHARACTER SET utf8 COLLATE utf8_b
|
|||
|
||||
CREATE TABLE IF NOT EXISTS ndb_binlog_index (Position BIGINT UNSIGNED NOT NULL, File VARCHAR(255) NOT NULL, epoch BIGINT UNSIGNED NOT NULL, inserts BIGINT UNSIGNED NOT NULL, updates BIGINT UNSIGNED NOT NULL, deletes BIGINT UNSIGNED NOT NULL, schemaops BIGINT UNSIGNED NOT NULL, PRIMARY KEY(epoch)) ENGINE=MYISAM;
|
||||
|
||||
--
|
||||
-- PERFORMANCE SCHEMA INSTALLATION
|
||||
-- Note that this script is also reused by mysql_upgrade,
|
||||
-- so we have to be very careful here to not destroy any
|
||||
-- existing database named 'performance_schema' if it
|
||||
-- can contain user data.
|
||||
-- In case of downgrade, it's ok to drop unknown tables
|
||||
-- from a future version, as long as they belong to the
|
||||
-- performance schema engine.
|
||||
--
|
||||
|
||||
set @have_old_pfs= (select count(*) from information_schema.schemata where schema_name='performance_schema');
|
||||
|
||||
SET @l1="SET @broken_tables = (select count(*) from information_schema.tables";
|
||||
SET @l2=" where engine != \'PERFORMANCE_SCHEMA\' and table_schema=\'performance_schema\')";
|
||||
SET @cmd=concat(@l1,@l2);
|
||||
|
||||
-- Work around for bug#49542
|
||||
SET @str = IF(@have_old_pfs = 1, @cmd, 'SET @broken_tables = 0');
|
||||
PREPARE stmt FROM @str;
|
||||
EXECUTE stmt;
|
||||
DROP PREPARE stmt;
|
||||
|
||||
SET @l1="SET @broken_views = (select count(*) from information_schema.views";
|
||||
SET @l2=" where table_schema='performance_schema')";
|
||||
SET @cmd=concat(@l1,@l2);
|
||||
|
||||
-- Work around for bug#49542
|
||||
SET @str = IF(@have_old_pfs = 1, @cmd, 'SET @broken_views = 0');
|
||||
PREPARE stmt FROM @str;
|
||||
EXECUTE stmt;
|
||||
DROP PREPARE stmt;
|
||||
|
||||
SET @broken_routines = (select count(*) from mysql.proc where db='performance_schema');
|
||||
|
||||
SET @broken_events = (select count(*) from mysql.event where db='performance_schema');
|
||||
|
||||
SET @broken_pfs= (select @broken_tables + @broken_views + @broken_routines + @broken_events);
|
||||
|
||||
--
|
||||
-- The performance schema database.
|
||||
-- This database is always created, even in --without-perfschema builds,
|
||||
-- Only drop and create the database if this is safe (no broken_pfs).
|
||||
-- This database is created, even in --without-perfschema builds,
|
||||
-- so that the database name is always reserved by the MySQL implementation.
|
||||
--
|
||||
|
||||
SET @cmd= "DROP DATABASE IF EXISTS performance_schema";
|
||||
|
||||
SET @str = IF(@broken_pfs = 0, @cmd, 'SET @dummy = 0');
|
||||
PREPARE stmt FROM @str;
|
||||
EXECUTE stmt;
|
||||
DROP PREPARE stmt;
|
||||
|
||||
SET @cmd= "CREATE DATABASE performance_schema character set utf8";
|
||||
|
||||
SET @str = IF(@broken_pfs = 0, @cmd, 'SET @dummy = 0');
|
||||
PREPARE stmt FROM @str;
|
||||
EXECUTE stmt;
|
||||
DROP PREPARE stmt;
|
||||
|
||||
--
|
||||
-- Unlike 'performance_schema', the 'mysql' database is reserved already,
|
||||
-- so no user procedure is supposed to be there
|
||||
--
|
||||
drop procedure if exists mysql.die;
|
||||
create procedure mysql.die() signal sqlstate 'HY000' set message_text='Unexpected content found in the performance_schema database.';
|
||||
|
||||
--
|
||||
-- For broken upgrades, SIGNAL the error
|
||||
--
|
||||
|
||||
SET @cmd="call mysql.die()";
|
||||
|
||||
SET @str = IF(@broken_pfs > 0, @cmd, 'SET @dummy = 0');
|
||||
PREPARE stmt FROM @str;
|
||||
EXECUTE stmt;
|
||||
DROP PREPARE stmt;
|
||||
|
||||
drop procedure mysql.die;
|
||||
|
||||
--
|
||||
-- From this point, only create the performance schema tables
|
||||
-- if the server is build with performance schema
|
||||
--
|
||||
|
||||
set @have_pfs= (select count(engine) from information_schema.engines where engine='PERFORMANCE_SCHEMA' and support != 'NO');
|
||||
|
||||
DROP DATABASE IF EXISTS performance_schema;
|
||||
|
||||
CREATE DATABASE performance_schema character set utf8;
|
||||
|
||||
--
|
||||
-- TABLE COND_INSTANCES
|
||||
--
|
||||
|
|
|
@ -1961,7 +1961,7 @@ const MY_CSET_OS_NAME charsets[]=
|
|||
{"cp10029", "macce", my_cs_exact},
|
||||
{"cp12001", "utf32", my_cs_unsupp},
|
||||
{"cp20107", "swe7", my_cs_exact},
|
||||
{"cp20127", "ascii", my_cs_exact},
|
||||
{"cp20127", "latin1", my_cs_approx},
|
||||
{"cp20866", "koi8r", my_cs_exact},
|
||||
{"cp20932", "ujis", my_cs_exact},
|
||||
{"cp20936", "gb2312", my_cs_approx},
|
||||
|
@ -1989,11 +1989,11 @@ const MY_CSET_OS_NAME charsets[]=
|
|||
#else /* not Windows */
|
||||
|
||||
{"646", "latin1", my_cs_approx}, /* Default on Solaris */
|
||||
{"ANSI_X3.4-1968", "ascii", my_cs_exact},
|
||||
{"ANSI_X3.4-1968", "latin1", my_cs_approx},
|
||||
{"ansi1251", "cp1251", my_cs_exact},
|
||||
{"armscii8", "armscii8", my_cs_exact},
|
||||
{"armscii-8", "armscii8", my_cs_exact},
|
||||
{"ASCII", "ascii", my_cs_exact},
|
||||
{"ASCII", "latin1", my_cs_approx},
|
||||
{"Big5", "big5", my_cs_exact},
|
||||
{"cp1251", "cp1251", my_cs_exact},
|
||||
{"cp1255", "hebrew", my_cs_approx},
|
||||
|
@ -2066,7 +2066,7 @@ const MY_CSET_OS_NAME charsets[]=
|
|||
|
||||
{"ujis", "ujis", my_cs_exact},
|
||||
|
||||
{"US-ASCII", "ascii", my_cs_exact},
|
||||
{"US-ASCII", "latin1", my_cs_approx},
|
||||
|
||||
{"utf8", "utf8", my_cs_exact},
|
||||
{"utf-8", "utf8", my_cs_exact},
|
||||
|
|
|
@ -2687,7 +2687,8 @@ enum options_mysqld
|
|||
OPT_SSL_CIPHER,
|
||||
OPT_SSL_KEY,
|
||||
OPT_WANT_CORE,
|
||||
OPT_ENGINE_CONDITION_PUSHDOWN
|
||||
OPT_ENGINE_CONDITION_PUSHDOWN,
|
||||
OPT_LOG_ERROR
|
||||
};
|
||||
|
||||
#endif /* MYSQL_SERVER */
|
||||
|
|
|
@ -3962,6 +3962,11 @@ static int init_server_components()
|
|||
else
|
||||
fn_format(log_error_file, log_error_file_ptr, mysql_data_home, ".err",
|
||||
MY_UNPACK_FILENAME | MY_SAFE_PATH);
|
||||
/*
|
||||
_ptr may have been set to my_disabled_option or "" if no argument was
|
||||
passed, but we need to show the real name in SHOW VARIABLES:
|
||||
*/
|
||||
log_error_file_ptr= log_error_file;
|
||||
if (!log_error_file[0])
|
||||
opt_error_log= 0; // Too long file name
|
||||
else
|
||||
|
@ -7357,6 +7362,14 @@ mysqld_get_one_option(int optid,
|
|||
global_system_variables.optimizer_switch&=
|
||||
~OPTIMIZER_SWITCH_ENGINE_CONDITION_PUSHDOWN;
|
||||
break;
|
||||
case OPT_LOG_ERROR:
|
||||
/*
|
||||
"No --log-error" == "write errors to stderr",
|
||||
"--log-error without argument" == "write errors to a file".
|
||||
*/
|
||||
if (argument == NULL) /* no argument */
|
||||
log_error_file_ptr= const_cast<char*>("");
|
||||
break;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -895,7 +895,8 @@ static Sys_var_mybool Sys_trust_function_creators(
|
|||
|
||||
static Sys_var_charptr Sys_log_error(
|
||||
"log_error", "Error log file",
|
||||
READ_ONLY GLOBAL_VAR(log_error_file_ptr), CMD_LINE(OPT_ARG),
|
||||
READ_ONLY GLOBAL_VAR(log_error_file_ptr),
|
||||
CMD_LINE(OPT_ARG, OPT_LOG_ERROR),
|
||||
IN_FS_CHARSET, DEFAULT(disabled_my_option));
|
||||
|
||||
static Sys_var_mybool Sys_log_queries_not_using_indexes(
|
||||
|
|
|
@ -6983,9 +6983,18 @@ static int my_uca_scanner_next_any(my_uca_scanner *scanner)
|
|||
scanner->send)) <= 0))
|
||||
return -1;
|
||||
|
||||
scanner->page= wc >> 8;
|
||||
scanner->code= wc & 0xFF;
|
||||
scanner->sbeg+= mb_len;
|
||||
if (wc > 0xFFFF)
|
||||
{
|
||||
/* Return 0xFFFD as weight for all characters outside BMP */
|
||||
scanner->wbeg= nochar;
|
||||
return 0xFFFD;
|
||||
}
|
||||
else
|
||||
{
|
||||
scanner->page= wc >> 8;
|
||||
scanner->code= wc & 0xFF;
|
||||
}
|
||||
|
||||
if (scanner->contractions && !scanner->page &&
|
||||
(scanner->code > 0x40) && (scanner->code < 0x80))
|
||||
|
|
|
@ -50,8 +50,6 @@
|
|||
static unsigned long lfactor[9]=
|
||||
{ 1L, 10L, 100L, 1000L, 10000L, 100000L, 1000000L, 10000000L, 100000000L };
|
||||
|
||||
#define REPLACEMENT_CHAR 0xFFFD;
|
||||
|
||||
|
||||
|
||||
#ifdef HAVE_CHARSET_mb2_or_mb4
|
||||
|
@ -1145,7 +1143,7 @@ my_tosort_utf16(MY_UNICASE_INFO **uni_plane, my_wc_t *wc)
|
|||
}
|
||||
else
|
||||
{
|
||||
*wc= REPLACEMENT_CHAR;
|
||||
*wc= MY_CS_REPLACEMENT_CHARACTER;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1874,7 +1872,7 @@ my_tosort_utf32(MY_UNICASE_INFO **uni_plane, my_wc_t *wc)
|
|||
}
|
||||
else
|
||||
{
|
||||
*wc= REPLACEMENT_CHAR;
|
||||
*wc= MY_CS_REPLACEMENT_CHARACTER;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1720,9 +1720,6 @@ MY_UNICASE_INFO *my_unicase_turkish[256]=
|
|||
};
|
||||
|
||||
|
||||
#define REPLACEMENT_CHAR 0xFFFD;
|
||||
|
||||
|
||||
static inline void
|
||||
my_tosort_unicode(MY_UNICASE_INFO **uni_plane, my_wc_t *wc)
|
||||
{
|
||||
|
@ -1734,7 +1731,7 @@ my_tosort_unicode(MY_UNICASE_INFO **uni_plane, my_wc_t *wc)
|
|||
}
|
||||
else
|
||||
{
|
||||
*wc= REPLACEMENT_CHAR;
|
||||
*wc= MY_CS_REPLACEMENT_CHARACTER;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1757,7 +1754,7 @@ my_wildcmp_unicode(CHARSET_INFO *cs,
|
|||
{
|
||||
int result= -1; /* Not found, using wildcards */
|
||||
my_wc_t s_wc, w_wc;
|
||||
int scan, plane;
|
||||
int scan;
|
||||
int (*mb_wc)(struct charset_info_st *, my_wc_t *,
|
||||
const uchar *, const uchar *);
|
||||
mb_wc= cs->cset->mb_wc;
|
||||
|
|
Loading…
Add table
Reference in a new issue