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

Manually Paste Clipboard Data Into Results Window?

forums forums SQLyog Using SQLyog Manually Paste Clipboard Data Into Results Window?

  • This topic is empty.
Viewing 8 reply threads
  • Author
    Posts
    • #11571
      sqldave
      Member

      I have a question about using clipboard data when manually updating a table using the RESULTS window.

      I'm using 8.05 enterprise. I'm working on a big project in which I have to manually enter a lot of data into a table (no PK, no indexes).

      Using the codebox example below, if I have copied the teacher name of “Crabtree” into the clipboard, and now I want to update the third row (Suzy Onion) —

      1. I set the window to the table name so that I can manually enter data.

      2. I go to row 3 (Suzy).

      3. I type an “x” into the `tag` column.

      4. I tab across to the `teacher` column.

      5. I press CONTROL-V to paste in the name “Crabtree”. Looks OK.

      6. I “Page Down” to the next row (to “save” the data).

      7. Row #3 appears to be just like I want it to look. It “appears” that the data has been saved.

      8. I do another query to view the entire table.

      9. The data I inputed into row # 3 has NOT been saved.

      So, my question is — Is this the expected behavior for SQLyog? My expectation would be that I can use clipboard data to “paste into” a cell, just as I would type in the data, but I don't seem to able to do this.

      Thank you for any help!

      [codebox]/*[11:09:02 AM][ 406 ms]*/ DROP TABLE IF EXISTS students ;

      /*[11:09:02 AM][ 32 ms]*/ CREATE TABLE `students` ( `tag` CHAR(1) NOT NULL, `last_name` CHAR(20) NOT NULL, `first_name` CHAR(15) NOT NULL, `teacher` CHAR(20) NOT NULL ) ENGINE=INNODB DEFAULT CHARSET=latin1 ;

      /*[11:09:02 AM][ 15 ms]*/ INSERT INTO students ( tag,last_name,first_name,teacher ) VALUES ( “x”,”Apricot”,”John”,”Crabtree”) , ( “x”,”Carrot”,”Bob”,”Crabtree” ) , ( “”,”Onion”,”Suzy”,”” ) , ( “”,”Zucchini”,”Tommy”,”” ) ;

      /*[11:09:02 AM][ 0 ms]*/ SELECT * FROM students ORDER BY last_name , first_name ;

      /*[11:09:11 AM][ 0 ms]*/ SHOW FULL FIELDS FROM `students`;

      /*[11:09:11 AM][ 0 ms]*/ SHOW KEYS FROM `students`;

      /*[11:09:19 AM][ 0 ms]*/ SELECT COUNT(*) FROM `students` WHERE `tag`='x' AND `last_name`='Onion' AND `first_name`='Suzy' AND `teacher`='';

      /*[11:09:19 AM][ 0 ms]*/ UPDATE `students` SET `tag`='x',`last_name`='Onion',`first_name`='Suzy',`teacher`='Crabtree' WHERE `tag`='x' AND `last_name`='Onion' AND `first_name`='Suzy' AND `teacher`='';

      [/codebox]

    • #29274
      peterlaursen
      Participant

      Of course it should make no difference how you enter data into a cell.

      1)

      Are you telling that with 'paste from clipboard' you get another behavior as compared to 'type with keyboard'?

      2)

      Is this UDATE statement correct (what you did)

      Code:
      UPDATE `students` SET `tag`='x',`last_name`='Onion',`first_name`='Suzy',`teacher`='Crabtree' WHERE `tag`='x' AND `last_name`='Onion' AND `first_name`='Suzy' AND `teacher`='';

      .. changed `teacher` from '' (empty string) to 'Crabtree'?

      (I still do not understand why you do not add an auto_increment PK to your tables. You will get lots of issues (example: no protection against duplicate rows) and bad performance!)

    • #29275
      sqldave
      Member
      peterlaursen wrote on Jun 30 2009, 11:55 AM:
      Of course it should make no difference how you enter data into a cell.

      1)

      Are you telling that with 'paste from clipboard' you get another behavior as compared to 'type with keyboard'?

      2)

      Is this UDATE statement correct (what you did)

      Code:
      UPDATE `students` SET `tag`='x',`last_name`='Onion',`first_name`='Suzy',`teacher`='Crabtree' WHERE `tag`='x' AND `last_name`='Onion' AND `first_name`='Suzy' AND `teacher`='';

      .. changed `teacher` from '' (empty string) to 'Crabtree'?

      (I still do not understand why you do not add an auto_increment PK to your tables. You will get lots of issues (example: no protection against duplicate rows) and bad performance!)

      Thanks for your help.

      1. Yes, this seems to be the case in my example.

      2. Yes. As you can see, the UPDATE statement did not “capture” my pasted data (using CONTROL-V to paste teacher “Crabtree”).

      3. So far, I am the sole user of MySQL for my projects. Because I get most of my data from a big state-wide database (operated by many professional DBAs), I don't have to worry about duplicate data. My biggest table is only about 50,000 rows and my longest MySQL “program” is about 1700 lines and takes only 8 minutes to run, which is fine for me. A nice coffee break.

      Thanks!

    • #29276
      peterlaursen
      Participant

      It did capture as far as I can see. Formatting a little will show.

      UPDATE `students`

      SET `tag`='x',`last_name`='Onion',`first_name`='Suzy',`teacher`='Crabtree'

      WHERE `tag`='x' AND `last_name`='Onion' AND `first_name`='Suzy' AND `teacher`='';

      In the SET clause (new data) it reads …`teacher`='Crabtree'

      In the WHERE clause (old data) it reads …`teacher`=''

      … so the `teacher` column should change from '' (empty string) to 'Crabtree'

      What am I missing?

    • #29277
      sqldave
      Member
      peterlaursen wrote on Jun 30 2009, 12:43 PM:
      It did capture as far as I can see. Formatting a little will show.

      UPDATE `students`

      SET `tag`='x',`last_name`='Onion',`first_name`='Suzy',`teacher`='Crabtree'

      WHERE `tag`='x' AND `last_name`='Onion' AND `first_name`='Suzy' AND `teacher`='';

      In the SET clause (new data) it reads …`teacher`='Crabtree'

      In the WHERE clause (old data) it reads …`teacher`=''

      … so the `teacher` column should change from '' (empty string) to 'Crabtree'

      What am I missing?

      In my original post, did you follow the steps and attempt to duplicate my activity? If you did, I think you will see what I mean. When I follow those sets, the data is not saved.

      I just verified this once again on my computer.

      I don't know how I can state the case any more plainly. It should be easy to reproduce the behavior.

      Now, either I'm expecting something to happen that isn't meant to happen in SQLyog — OR — there seems to be an issue in the program. I just want to know which.

      Thanks!

    • #29278
      navyashree.r
      Member

      Hi,

      Issue confirmed. Added in our tracker,

      http://code.google.com/p/sqlyog/issues/detail?id=1110

      Regards,

      Navya

    • #29279
      sqldave
      Member
      navyashree.r wrote on Jul 1 2009, 01:16 AM:
      Hi,

      Issue confirmed. Added in our tracker,

      http://code.google.com/p/sqlyog/issues/detail?id=1110

      Regards,

      Navya

      Thank you very much for looking into this! I think this is why SQLyog is such a great product.

    • #29280
      navyashree.r
      Member

      Hi,

      Fixed internally and available in next 8.13 Beta release probably Monday.

      Regards,

      Navya

    • #29281
      navyashree.r
      Member

      Hi,

      This issue is fixed and available in 8.13 beta2, publicly available!

      Please refer to:

      http://www.webyog.com/blog/2009/07/15/sqly…-been-released/

      Please let us know the status.

      Thank you.

      Regards,

      Navya

Viewing 8 reply threads
  • You must be logged in to reply to this topic.