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

Get Advance Warning Of Rows Affected

forums forums SQLyog SQLyog: Bugs / Feature Requests Get Advance Warning Of Rows Affected

  • This topic is empty.
Viewing 1 reply thread
  • Author
    Posts
    • #12360
      jrosen1040
      Member

      I noticed that after running an update query, SQLyog tells me how many rows were affected. Is there a way to get this count without actually running the update? It would be good to be able to verify that I'm not about to update more rows than what I expected. Thanks.

    • #32362

      Hi,

      There is no way MySQL provides to get the number of rows going to be affected in advance for the Update Query.

      SQLyog just displays the messages returned by the MySQL Server. So until You run the Query, You can not know the number of rows going to be affected.

      But You can know the no of rows in advance in another way.

      Suppose,

      You have an Update Query : Update mytable Set itemname = 'skc' where itemid < 10; Convert it to : SELECT count(*) FROM mytable WHERE itemid < 10;

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