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

Sql Dump: Export Table Names In Orig Case

forums forums SQLyog SQLyog: Bugs / Feature Requests Sql Dump: Export Table Names In Orig Case

  • This topic is empty.
Viewing 7 reply threads
  • Author
    Posts
    • #10393
      maxhugen
      Participant

      Its rather annoying to have all the table names in the SQL dump reduced to lower case. A restore then buggers up the original names, so that 'budgetTransaction' ends up as 'budgettransaction'.

      I note that the original case of the table columns is preserved OK.

      Cheers, Max

    • #24282
      peterlaursen
      Participant

      It is MySQL that has this (default) behaviour on Windows!  It is NOT SQLyog that changes the lettercase.

      In MySQL configuration (my.ini/my/cnf)you will have set set the variable In the [mysqld] section like

      Code:
      lower_case_table_names=2

       

      Then (on Windows) table names will be stored with the LETTERCASE as in the SQL.

      Search the MySQL documentation on 'lower_case_table_names'

      There is no way for us to 'override' or change the setting.  

      Configuration demands access to the configuration file.

      SQLyog connects to MySQL only and does not have access to the file system on the host!

    • #24283
      peterlaursen
      Participant

      but I do not understand “I note that the original case of the table columns is preserved OK.”

      Please try to create a table like `MYTABLE`.  Does it become `mytable`or not if you 'refresh' the Object Browser?

      If you are reporting aan issue with SQLyog (`MYTABLE` dumped as `mytable`), then please (always) tell the program version and explain detailed how to reproduce!  It is 'rather annoying' when people don't! 😛

    • #24284
      DonQuichote
      Member

      Please note: Some MySQL versions do not use the lower_case_table_names setting everywhere. I use MySQL 5.0.22 locally, and it uses lowercase table names in the SHOW TABLE output even though I have set it to store the table names in the correct case.

      It seems that SQLyog uses the SHOW TABLE command, so this leads to problems on input on a Linux server later. The precise problem is that all names have the correct case, except in the FOREIGN KEY clauses. If I repair the foreign key clauses in the dump, the dump files work just fine for communication with a Linux server.

    • #24285
      peterlaursen
      Participant

      “The precise problem is that all names have the correct case ..except”

      If so it is a MySQL bug that should not be accepted but reported and fixed (if it is not allready in 5.0.41)

    • #24286
      peterlaursen
      Participant

      this is the situation with MySQL 5.0.41:

      select version();

      /*

      version()


      5.0.41-community-nt

      */

      show variables like 'lower_case_table_names';

      /*

      Variable_name Value



      lower_case_table_names 2

      */

      show tables like 'Parenttable';

      /*

      Tables_in_t4 (Parenttable)


      Parenttable

      */

      show create table childtable;

      /*

      CREATE TABLE `childtable` (

      `id` bigint(20) NOT NULL,

      `keyrow` bigint(20) default NULL,

      PRIMARY KEY (`id`),

      KEY `FK_Childtable` (`keyrow`), CONSTRAINT `FK_Childtable`

      FOREIGN KEY (`keyrow`) REFERENCES `parenttable` (`id`) )

      ENGINE=InnoDB DEFAULT CHARSET=latin1

      */

      and alternatively using LOWERCASE with 'Show Tables' still returns the table in UPERCASE.

      show tables like 'parenttable';

      /*

      Tables_in_t4 (Parenttable)


      Parenttable

      */

    • #24287
      peterlaursen
      Participant

      this is definitely a MySQL bug in my opinion!

      However with MySQL 4.0 everything seems to be OK!

    • #24288
      peterlaursen
      Participant
Viewing 7 reply threads
  • You must be logged in to reply to this topic.