Bug #24293 '\Z' token is not handled correctly in views

Submitted: 14 Nov 2006 12:12 Modified: 24 Jan 2007 21:15
Reporter: Alexander Nozdrin Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Views Severity:S3 (Non-critical)
Version:5.0 BK OS:
Assigned to: Alexander Nozdrin CPU Architecture:Any

[14 Nov 2006 12:12] Alexander Nozdrin
Description:
If SELECT-part of CREATE VIEW statement contains '\Z',
it is not handled correctly.

The problem is in String::print().
Symbol with code 032 (26) is replaced with '\z',
which is not supported by the lexer.

How to repeat:
mysql> CREATE VIEW v1 AS SELECT 'The\ZEnd';
Query OK, 0 rows affected (0.00 sec)

mysql> select * from v1;
+---------+
| The▒End |
+---------+
| ThezEnd |
+---------+
1 row in set (0.00 sec)

mysql> show create view v1\G
*************************** 1. row ***************************
       View: v1
Create View: CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select _latin1'ThezEnd' AS `The▒End`
1 row in set (0.00 sec)
[4 Dec 2006 13:11] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/16378

ChangeSet@1.2317, 2006-12-04 16:04:27+03:00, anozdrin@booka. +4 -0
  Fix for BUG#24293: '\Z' token is not handled correctly in views.
  
  If SELECT-part of CREATE VIEW statement contains '\Z',
  it is not handled correctly.
  
  The problem was in String::print().
  Symbol with code 032 (26) is replaced with '\z',
  which is not supported by the lexer.
  
  The fix is to replace the symbol with '\Z'.
[18 Dec 2006 16:51] Marc ALFF
Approved by email
[19 Dec 2006 12:32] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/17155

ChangeSet@1.2320, 2006-12-19 15:32:02+03:00, anozdrin@alik. +3 -0
  Fix for BUG#24293: '\Z' token is not handled correctly in views.
  
  If SELECT-part of CREATE VIEW statement contains '\Z',
  it is not handled correctly.
  
  The problem was in String::print().
  Symbol with code 032 (26) is replaced with '\z',
  which is not supported by the lexer.
  
  The fix is to replace the symbol with '\Z'.
[15 Jan 2007 16:06] Marc ALFF
Merged into 5.0.34 and 5.1.15
[24 Jan 2007 21:15] Paul DuBois
Noted in 5.0.34, 5.1.15 changelogs.

A view was not handled correctly if the SELECT part contained `\Z'.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.041 sec. using MySQL 8.4.7-u6-cloud

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