Results 1 to 4 of 4
  1. #1
    Join Date
    Dec 2007
    Posts
    21

    Unanswered: View performance issues

    Hello,
    So I have converted a database from MSSQL to MySQL and for the most part it's all good. The big issue I'm having is with the performance with using views in MySQL(5.0.45). The query I run in MSSQL returns in 1 second and in MySQL it takes 1 and a half hours. Now I did not expect it to be as fast a MSSQL but not that slow.

    Any suggestions?

    Thanks,
    tom

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    have you analyzed the index usage?

    do an EXPLAIN on the query and see if you can find anything like "filesort"
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  3. #3
    Join Date
    Dec 2007
    Posts
    21
    Yes, I do see a filesort.

  4. #4
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    did you declare any indexes on the table?

    mysql is nice because scripting a table is ~way~ easier than in microsoft sql server

    do a SHOW CREATE TABLE tablename for each table involved in the query -- it will show you the indexes on the table
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •