MySQL Community Server 5.0.75 has been released in source

2008-12-22 Thread Joerg Bruehe
Dear MySQL users, MySQL Community Server 5.0.75, a new version of the popular Open Source Database Management System, has been released. The release is now available in source (only) form from our download pages at http://dev.mysql.com/downloads/ and mirror sites. Note that not all mirror

MySQL Cluster 6.3.20 has been released

2008-12-22 Thread Joerg Bruehe
Dear MySQL Cluster users, MySQL Cluster 6.3.20, a new version of the popular Open Source Database Management System, has been released. MySQL Cluster is a High Availability Database for Real-Time, Mission Critical Applications. The release is now available in source and binary form for a number

Re: Distinct Query Problem

2008-12-22 Thread Tompkins Neil
Hi I'm having trouble trying to figure this out. Any help/example would be grateful. Thanks Neil On Sun, Dec 21, 2008 at 4:30 PM, Baron Schwartz ba...@xaprb.com wrote: On Fri, Dec 19, 2008 at 1:03 PM, Tompkins Neil neil.tompk...@googlemail.com wrote: of products for all suppliers for a

Problem with MySQL prompt

2008-12-22 Thread Stefano Elmopi
I need advice. I have three instances of MySQL on a single server. How can I change the MySQL prompt depending of the instance on which connecting ? If I put the variable prompt in the general my.cnf, the prompt is changed but for all instances. If I put in the variable prompt in the my.cnf

Re: Problem with MySQL prompt

2008-12-22 Thread Claudio Nanni
Ciao Stefano, how do you connect to the different instances? if you use different operating system users or different mysql home directories just put in the home directory of each user a .my.cnf file (or my.cnf in the mysql home) with just the prompt setting in the [mysql] section. NOTE: in the

Re: Problem with MySQL prompt

2008-12-22 Thread Warren Young
Stefano Elmopi wrote: If I put the variable prompt in the general my.cnf, the prompt is changed but for all instances. If I put in the variable prompt in the my.cnf associated with the instance in the [mysql] section, the prompt does not change. This is because the client reads from my.cnf

Re: Problem with MySQL prompt

2008-12-22 Thread Krishna Chandra Prajapati
Hi Stefano, You are running three mysql instance on single server. You can have three my.cnf say my.cnf, my1.cnf, my2.cnf with different port and socket and other information in them. In this way you can set the prompt for different instance. On Mon, Dec 22, 2008 at 3:46 PM, Stefano Elmopi

Re: Problem with MySQL prompt

2008-12-22 Thread Stefano Elmopi
Thanks for the all answers !!! It's ok, even if I have three different my.cnf for my three instances, my general my.cnf is: [mysqld_multi] mysqld = /opt/local/mysql50/bin/mysqld_safe mysqladmin = /opt/local/mysql50/bin/mysqladmin user = root password = mysys2008srv log =

Re: Distinct Query Problem

2008-12-22 Thread Tompkins Neil
Hi, If anyone could point me in the right direction, I'd be most grateful. Thanks ! Neil On Mon, Dec 22, 2008 at 9:55 AM, Tompkins Neil neil.tompk...@googlemail.com wrote: Hi I'm having trouble trying to figure this out. Any help/example would be grateful. Thanks Neil On Sun, Dec

Re: Distinct Query Problem

2008-12-22 Thread Tompkins Neil
OK, I've made further progress by changing GROUP BY ProductTB.ProductID, MasterTB.MasterID to GROUP BY MasterTB.MasterID. However ProductTB.Supplier is showing the incorrect Supplier. Why is this ? Thanks Neil On Mon, Dec 22, 2008 at 11:45 AM, Tompkins Neil neil.tompk...@googlemail.com wrote:

Re: Problem with MySQL prompt

2008-12-22 Thread Simon J Mudd
prajapat...@gmail.com (Krishna Chandra Prajapati) writes: You are running three mysql instance on single server. You can have three my.cnf say my.cnf, my1.cnf, my2.cnf with different port and socket and other information in them. In this way you can set the prompt for different instance.

Re: Distinct Query Problem

2008-12-22 Thread Brent Baisley
On Fri, Dec 19, 2008 at 1:03 PM, Tompkins Neil neil.tompk...@googlemail.com wrote: Hi, I've the following query which I'm having problems with. Basically I have a 5 tables as follows : MasterTB - Contains list of master records LookupTB - Contains relationship between MasterTB to ProductTB

Average Rating, like Netflix

2008-12-22 Thread Brian Dunning
Pretend I'm Netflix and I want to return a list of found movies, including the average of related ratings for each movie. Something like this: select movies.*, average(ratings.rating) from movies, ratings where movies.movie_id=ratings.movie_id I'm sure that's wrong in about 10 different

Re: Average Rating, like Netflix

2008-12-22 Thread Brian Dunning
If I did the left join to include movies with no ratings, how would I tell if it had no ratings? If I used mysql_fetch_array in PHP, would $result['rating'] == 0, or '', or NULL, or what? On Dec 22, 2008, at 9:29 AM, Brent Baisley wrote: The biggest problem is your join condition (and no

installation nightmare

2008-12-22 Thread PJ
I feel like one big fat stupid sheep problem SOLVED... It turns out that the root of all the problems was my own little forgetful brain... I had forgotten that I had changed the permissions on the apache22/data files to 766 which prevented the execution of all the php scripts which

Re: Average Rating, like Netflix

2008-12-22 Thread Brent Baisley
The ratings field would be NULL. You could also add a count in your query to tell how many ratings there were. If count is 0, you know there are no ratings. SELECT count(ratings.rating_id) AS rate_count, ... Brent Baisley On Mon, Dec 22, 2008 at 12:39 PM, Brian Dunning br...@briandunning.com

Re: replication of databases

2008-12-22 Thread Bryan Irvine
On Sun, Dec 21, 2008 at 8:35 AM, Baron Schwartz ba...@xaprb.com wrote: Hi Bryan, On Wed, Dec 17, 2008 at 5:35 PM, Bryan Irvine sparcta...@gmail.com wrote: I've got a master-master set up and I'm trying to figure out the best way to add new databases to the cluster. I've not set anything for

Re: How many users access MySQL

2008-12-22 Thread Andy Shellam
Hi If you don't mind keeping the general log, you can periodically parse it. I read that MySQL 5.1 (or some later version) will have an option to keep the general log in a table - that will be very handy. Be careful if you use this option (logging to a table) - while it's an extremely

Re: Average Rating, like Netflix

2008-12-22 Thread Andy Shellam
Or you could wrap your entire SELECT in another query, and do an IFNULL around the rating field to convert it to 0 (or some other value important to you) as follows: SELECT movie_id, ... any other fields from movies table you want ..., IFNULL(ratings, 0) AS rating FROM ( SELECT

Re: replication of databases

2008-12-22 Thread Baron Schwartz
Right. Unless you have some other settings (binlog-do-db or binlog-ignore-db on the master?) that are interfering You saw this ^ right? on master: mysql show master status; +--+--+--+--+ | File | Position | Binlog_Do_DB |

RE: replication of databases

2008-12-22 Thread Raghani, Sonal (IE10)
Hi, In your case replication will reflect only the changes done by selecting the default db as mysql as the binlog_do_db parameter is set to mysql. Regards Sonal -Original Message- From: baron.schwa...@gmail.com [mailto:baron.schwa...@gmail.com] On Behalf Of Baron Schwartz Sent: Tuesday,

On fighting with master-slave replication lag

2008-12-22 Thread xufeng
Hello everyone, In my production system, I set up MySQL 5.0.67 master/slave replication, and recently I met with master/slave replication lag problem. Is there a good monitoring tool or some other tools to detect and discover this latency on slave? Any suggestion is welcomed. Thank you in advance.