Unsupported Screen Size: The viewport size is too small for the theme to render properly.

Unpredictable SQL execution

forums forums SQLyog Using SQLyog Unpredictable SQL execution

  • This topic is empty.
Viewing 1 reply thread
  • Author
    Posts
    • #7890
      u3003-04-23
      Member

      Running SQLyog v3.1

      Win2k running IIS

      mySQL Server

      I am having problems running delete queries using SQLyog.

      For example, when I first go into it, I can run a query like:

      delete from `data`.`news` where newsID=363;

      and it works.

      I can then do another insert into my db. and try this SQL:

      delete from `data`.`news` where newsID=364;

      and I get this error:

      Error Code : 1064

      You have an error in your SQL syntax near 'delete from `data`.`news` where newsID=364' at line 3

      (0 ms taken)

      But if I close and restart SQLyog the SQL statement will be executed:

      (1 row(s) affected)

      (0 ms taken)

      Any ideas?

      Thanks

      Jim

    • #14186
      CalEvans
      Member

      Jim,

      Are there any sql commands in the window that are not terminated by a ;? SQLyog is very picky that ALL commands must be terminated by a ; if there are multiple commands in the window, EVEN IF IT'S NOT A COMMAND YOU ARE EXECUTING. Not sure why but check it out. This would explain why closing and reopening would cause it to work.

      BTW, this most commonly hits me when I use ENTER to view the contents of a table. In 3.11 it puts a ; on the line BEFORE the command to make sure that any command there is properly terminated (I guess) but it does NOT terminate the select with a ;. Therefore If I do this and then try and type in a command below it I will get an error in my sql and to fix it I simply terminate the SELECT with a ;.

      Clear as mud?

      HTH,

      =C=

Viewing 1 reply thread
  • You must be logged in to reply to this topic.