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

Query Builder Without Database Name

forums forums SQLyog SQLyog BETA Discussions Query Builder Without Database Name

Viewing 9 reply threads
  • Author
    Posts
    • #12275
      Stephan123
      Member

      Hello !

      I work for several days with SQLyog.

      It's a great program.

      In most cases i work with the query builder.

      I use the generated questions in my new project.

      For example:

      select

      name.user,

      lastname.user

      from

      group.user, group.role-id

      where

      And here is my problem. In the generated

      question is the name of the database.

      Is there an way to generat questions without database name's.

      Your sincerly

      Stephan

      (Sorry for my bad english)

    • #32028
      peterlaursen
      Participant

      No such option.

      However if you want to replcae database name `this` with `that` just copy the query to an editor tab and use 'search and replace'. Also you may replace ” `this`. ” with ” '' ” (empty string) if you do not want to use 'fully qualified table names'.

    • #32029

      i would like to have an option to remove the “database.tablename” from queries made with the builder like the ´ could be removed.

      exampel:

      SELECT table1.*, table2.*

      FROM dbnamehere.table1 LEFT JOIN dbnamehere.table2 ON (table1.t1ID = table2.t2ID)

      WHERE ….

      =

      SELECT table1.*, table2.*

      FROM table1 LEFT JOIN table2 ON (table1.t1ID= table2.t2ID)

      WHERE ….

      with no “dbnamehere.”

    • #32030
      peterlaursen
      Participant

      Is it a big deal to 'search and replace' (CTRL+H) “`databasename`.” with an empty string after copying to editor?

    • #32031
      'peterlaursen' wrote:

      Is it a big deal to 'search and replace' (CTRL+H) “`databasename`.” with an empty string after copying to editor?

      i think os yes , sins im sitting all day working in sqlyog on 1 screen and notpad++ onm the other , would be much better to just have an option to remove it like the remove ´ option.

    • #32032
      peterlaursen
      Participant

      OK .. I think you have a point.

      1) If the query you generate should be executed from SQLyog the fully qualified table name makes sense, because if you change the databae context the query will fail (at best).

      2) But if you generate a query solely with the purpose to use it in an application/script where the database name may be different, a query without the database name would be useful.

    • #32033
      sathish
      Member

      Hello,

      This feature request is already listed in our issue tracker: http://code.google.com/p/sqlyog/issues/detail?id=1107 we will schedule this according to priority.

      Regards,

      Sathish

    • #32034
      'peterlaursen' wrote:

      OK .. I think you have a point.

      1) If the query you generate should be executed from SQLyog the fully qualified table name makes sense, because if you change the databae context the query will fail (at best).

      2) But if you generate a query solely with the purpose to use it in an application/script where the database name may be different, a query without the database name would be useful.

      ye, number two describes what i do sins i make the queries in sqlyog and then paste them into PHP scripts, and sins i use 1 development DB and 1 live DB it would be usefull to not have to delete the database name every single time.

      'sathish' wrote:

      Hello,

      This feature request is already listed in our issue tracker: http://code.google.com/p/sqlyog/issues/detail?id=1107 we will schedule this according to priority.

      Regards,

      Sathish

      ye , true, it was added… , over 2.5 years ago…, and even tho several people have asked for the feature in the last 2 years it still havent been added…

    • #32035
      ashwin
      Member
      Quote:
      Is there an way to generat questions without database name's.

      Hello,

      We have released 9.6 Beta3 with this feature. “It is now optional if Query Builder will create statements with ‘fully qualified tablenames’ or not.” Refer: http://www.webyog.com/blog/2012/02/08/sqlyog-mysql-gui-9-6-beta-3-released/

      Regards,

      Ashwin A

    • #32036

      fishy place to put the setting, thought it would be under the “Generate queries using backquotes(`)” in preferences, but its still a realy nice feature, cheers.

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