Re: Counting Multiple Fields
Rhino wrote: SELECT SiteCode, TypeOfJob, count(TypeOfJob) As countJobType FROM jobs GROUP BY SiteCode I think he wants something like select SiteCode, TypeOfJob, count(TypeOfJob) As countJobType, (select * from jobs) as alljobs, countJobType*100.0/alljobs FROM jobs GROUP BY SiteCode I'm pretty convinced something like this would work in Oracle or DB2 and maybe there is way in MySQL for such a query, but I'm using currently only mysql-4.1.12-3.RHEL4.1 and that is too old to check. Also, it is always a good idea to state which version of MySQL you are using; older versions, which are still in widespread use, don't have all the functionality of newer versions. That means that a solution that works fine in a newer version may not work at all in an older version or may have to be adapted to work. I agree. -- Mladen Adamovic http://home.blic.net/adamm http://www.shortopedia.com http://www.froola.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: MySQLMigrationsToolkit ...
Rafal Kedziorski wrote: The SQL create statements could not be created (error: 0). MigrationMysql.dataBulkTransfer :Java heap space What can I do? That is Java memory related problem. Check out where it invoke the Java VM if possible and add memory parametars like -Xms256m -Xmx900m (it assume that you have 1GB memory, if you have 512MB put -XMx420m). Hope it helps. -- Mladen Adamovic http://home.blic.net/adamm http://www.shortopedia.com http://www.froola.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: best method to backup this mysql data
Neil Tompkins wrote: I have a mySQL database running on linux. Can anyone recommend the best method to backup this data from a Windows XP machine on a scheduled basis ? My database server version at the moment is 3.23. Generally information about backups you could find at http://dev.mysql.com/doc/refman/5.0/en/backup.html You could make bash script of Linux computer to create backups and the easiest way is to put that script as cron jobs if you have access to the cron. You can also shedule Windows BAT script which use FTP to get this data from that Linux computer. Otherwise - I mean if you don't have FTP access to the files or cron jobs - it is more difficult IMHO. -- Mladen Adamovic http://home.blic.net/adamm http://www.shortopedia.com http://www.froola.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Query Optimization Question
Robert DiFalco wrote: In a previous database engine I was using an IN was more optimal than a . So, for example: SELECT * FROM table WHERE table.type IN (1,2,3); Where the possible values of type are 0-3, was appreciably faster than: SELECT * FROM table WHERE table.type 0; IN should be faster implemented with both hash tables and BTREE's so nowadays it should also be faster than as all MySQL implementation AFAIK use those well known data structures for indexes. I've been playing with the Query Browser and checking out the optimization documents and haven't been able to make a clear call on whether or not this is also the case with MySQL/InnoDB. TIA, R. -- Mladen Adamovic http://home.blic.net/adamm http://www.shortopedia.com http://www.froola.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Cannot connect to server
Sara Woglom wrote: I have just installed MySQL 5.0, and I am unable to connect to it from my own (remote) machine. It all works fine when I open mysqladmin from the server itself, so I know the installation is OK. I am working on a small LAN of about 15 PCs. When I try to telnet to the default port (3306), I get the following error: Telnet to port 3306: Host 'my-machine-name' is not allowed to connect to this MySQL server I am not a network person so I am having some trouble. Please advise if possible! You seem to have is privilage errors: check this out here http://dev.mysql.com/doc/mysql/en/grant.html -- Mladen Adamovic http://home.blic.net/adamm http://www.shortopedia.com http://www.froola.com