forums › forums › SQLyog › SQLyog: Bugs / Feature Requests › not parsing comments properly?
- This topic is empty.
-
AuthorPosts
-
-
October 30, 2003 at 7:52 pm #8225nelson1993Member
In version 3.61 when I execute a query (either with F5, Shift-F5, or Ctl-F5) that includes a comment, the parser does not seem to be able to separate the comment from the query. For example, executing the following block of text:
# this is a comment
ALTER TABLE `table1` CHANGE `parentId` `newId` INT(10) UNSIGNED DEFAULT “0” NOT NULL;
shows up in the History tab as follows:
[2:45:36 PM][ 0 ms] # this is a comment ALTER TABLE `table1` CHANGE `parentId` `newId` INT(10) UNSIGNED DEFAULT “0” NOT NULL
and the sql command is not executed. I seem to have to put a ';' on a line between the comment and the beginning of the sql statement to get the command to execute.
Am I just missing something obvious, or is this a bug?
thanks,
mn
-
October 31, 2003 at 8:07 am #15172ShadowMember
Interesting, SQLyog does not seem to regard line breaks as termination of comments. Should be corrected…
-
January 30, 2004 at 8:04 am #15173number_oneParticipant
I mentioned this way back with the release of SQLyog 3.5
Comments with the pound sign will no longer work because it wraps everything onto one line before parsing it as of version 3.5. Before that, it parsed each line with carriage return separately. So now the only way to reliably use comments is by enclosing a comment with /* */ type indicators.
Very, VERY annoying for someone who uses comments frequently and would like to comment out a very long query by simply putting a pound sign in front. I don't know why it hasn't been corrected, and IMHO there is no valid reason to say that this change is “by design”.
PLEASE, PLEASE fix this so I can stop using version 3.11
-
February 5, 2004 at 2:22 pm #15174RiteshMember
This bug was fixed in SQLyog 3.62. I executed the following sql in SQLyog 3.62 & 3.63 –
Code:#this is a comment
alter table `ritesh`.`db` ,change `Db` `Db` int (64) NOT NULL ,drop primary key, add primary key (`Host`, `Db`, `User` );The outputs are given in the attached images. I executed the above statement using F5 and Shift+F5.
SQLyog strips off all the carriage return characters before adding them to the History window. It will send the query to MySQL as entered by the user.
-
February 5, 2004 at 2:31 pm #15175RiteshMember
The above bug was present in SQLyog 3.61 as reported by nelson1993
-
-
AuthorPosts
- You must be logged in to reply to this topic.