Subquery Problem With mysql-4.0 (Works with mysql-5.0)
I face one problem with mysql4.0 I've two tables, one called company and the other called favorites. The relation between those two tables is CO_ID on the company table and MASTER_CO_ID on the favorites table. When I run the following query it works fine on mysql-5.0 but it give error with mysql-4.0. Query** SELECT c.MASTER_CO_ID as Expr1 FROM company LEFT OUTER JOIN (select MASTER_CO_ID,SLAVE_CO_ID from favorites where MASTER_CO_ID = '1' GROUP BY MASTER_CO_ID,SLAVE_CO_ID) c ON company.CO_ID = c.SLAVE_CO_ID GROUP BY c.MASTER_CO_ID *** Error with mysql4.0 #1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'select MASTER_CO_ID,SLAVE_CO_ID from favorites where MAS *** I have two tables company and favorites, like CREATE TABLE `company` ( `CO_ID` varchar(36) NOT NULL default '', `CO_NAME` varchar(50) default NULL, PRIMARY KEY (`CO_ID`), FULLTEXT KEY `CO_NAME` (`CO_NAME`,`INDUSTRY_NAME`,`CO_ADDR1`,`CO_ADDR2`,`CO_PIN`,`CO_URL`,`CO_INFO`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1; CREATE TABLE `favorites` ( `FAV_ID` bigint(20) NOT NULL auto_increment, `MASTER_CO_ID` varchar(36) default NULL, `SLAVE_CO_ID` varchar(36) default NULL, PRIMARY KEY (`FAV_ID`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=41 ;
Re: Subquery Problem With mysql-4.0 (Works with mysql-5.0)
2006/6/5, MySQL Nexeia [EMAIL PROTECTED]: I face one problem with mysql4.0 I've two tables, one called company and the other called favorites. The relation between those two tables is CO_ID on the company table and MASTER_CO_ID on the favorites table. When I run the following query it works fine on mysql-5.0 but it give error with mysql-4.0. Query** SELECT c.MASTER_CO_ID as Expr1 FROM company LEFT OUTER JOIN (select MASTER_CO_ID,SLAVE_CO_ID from favorites where MASTER_CO_ID = '1' GROUP BY MASTER_CO_ID,SLAVE_CO_ID) c ON company.CO_ID = c.SLAVE_CO_ID GROUP BY c.MASTER_CO_ID *** MySQL 4.0.x does not support subquery. Subqueries are only supported starting with 4.1. Error with mysql4.0 #1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'select MASTER_CO_ID,SLAVE_CO_ID from favorites where MAS *** I have two tables company and favorites, like CREATE TABLE `company` ( `CO_ID` varchar(36) NOT NULL default '', `CO_NAME` varchar(50) default NULL, PRIMARY KEY (`CO_ID`), FULLTEXT KEY `CO_NAME` (`CO_NAME`,`INDUSTRY_NAME`,`CO_ADDR1`,`CO_ADDR2`,`CO_PIN`,`CO_URL`,`CO_INFO`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1; CREATE TABLE `favorites` ( `FAV_ID` bigint(20) NOT NULL auto_increment, `MASTER_CO_ID` varchar(36) default NULL, `SLAVE_CO_ID` varchar(36) default NULL, PRIMARY KEY (`FAV_ID`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=41 ; -- http://www.w-fenec.org/ -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
synopsis of the problem (one line)
Description: How-To-Repeat: Fix: Submitter-Id: submitter ID Originator:root Organization: MySQL support: [none | licence | email support | extended email support ] Synopsis: Severity: Priority: Category: mysql Class: Release: mysql-4.1.19-standard (MySQL Community Edition - Standard (GPL)) Server: /usr/bin/mysqladmin Ver 8.41 Distrib 4.1.19, for pc-linux-gnu on i686 Copyright (C) 2000 MySQL AB MySQL Finland AB TCX DataKonsult AB This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL license Server version 4.1.19-standard Protocol version10 Connection Localhost via UNIX socket UNIX socket /var/lib/mysql/mysql.sock Uptime: 20 min 25 sec Threads: 1 Questions: 882 Slow queries: 0 Opens: 26 Flush tables: 1 Open tables: 20 Queries per second avg: 0.720 C compiler:gcc (GCC) 4.1.0 20060304 (Red Hat 4.1.0-3) C++ compiler: gcc (GCC) 4.1.0 20060304 (Red Hat 4.1.0-3) Environment: System: Linux vps.lvhost.net 2.6.15-1.2054_FC5xenU #1 SMP Tue Mar 14 16:53:12 EST 2006 i686 i686 i386 GNU/Linux Architecture: i686 Some paths: /usr/local/bin/perl /usr/bin/make /usr/bin/gmake /usr/bin/gcc /usr/bin/cc GCC: Using built-in specs. Target: i386-redhat-linux Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --with-cpu=generic --host=i386-redhat-linux Thread model: posix gcc version 4.1.1 20060525 (Red Hat 4.1.1-1) Compilation info: CC='gcc' CFLAGS='-O2 -g -march=i386 -mcpu=i686' CXX='gcc' CXXFLAGS='-O2 -g -march=i386 -mcpu=i686-felide-constructors -fno-exceptions -fno-rtti ' LDFLAGS='' ASFLAGS='' LIBC: lrwxrwxrwx 1 root root 11 May 16 04:21 /lib/libc.so.6 - libc-2.4.so -rwxr-xr-x 1 root root 1529400 May 12 06:09 /lib/libc-2.4.so -rw-r--r-- 1 root root 2651388 May 12 06:43 /usr/lib/libc.a -rw-r--r-- 1 root root 238 May 12 06:23 /usr/lib/libc.so lrwxrwxrwx 1 root root 10 May 4 19:01 /usr/lib/libc-client.a - c-client.a lrwxrwxrwx 1 root root 16 May 4 19:01 /usr/lib/libc-client.so - libc-client.so.1 -rwxr-xr-x 1 root root 858696 Feb 11 16:31 /usr/lib/libc-client.so.1 -rwxr-xr-x 1 root root 858668 Mar 1 08:46 /usr/lib/libc-client.so.2004g Configure command: ./configure '--disable-shared' '--with-zlib-dir=bundled' '--with-comment=MySQL Community Edition - Standard (GPL)' '--with-server-suffix=-standard' '--without-embedded-server' '--without-berkeley-db' '--with-innodb' '--without-vio' '--without-openssl' '--enable-assembler' '--enable-local-infile' '--with-mysqld-user=mysql' '--with-unix-socket-path=/var/lib/mysql/mysql.sock' '--prefix=/' '--with-extra-charsets=complex' '--exec-prefix=/usr' '--libexecdir=/usr/sbin' '--libdir=/usr/lib' '--sysconfdir=/etc' '--datadir=/usr/share' '--localstatedir=/var/lib/mysql' '--infodir=/usr/share/info' '--includedir=/usr/include' '--mandir=/usr/share/man' '--enable-thread-safe-client' '--with-readline' 'CC=gcc' 'CFLAGS=-O2 -g -march=i386 -mcpu=i686' 'CXXFLAGS=-O2 -g -march=i386 -mcpu=i686 -felide-constructors -fno-exceptions -fno-rtti ' 'CXX=gcc' 'LDFLAGS=' -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
sad asd as
dsa dsad
hierarchical sql
Hi everyone, Someone know if mysql 5 has hierarchical sql? Thanks. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: hierarchical sql
João Cândido de Souza Neto wrote: Hi everyone, Someone know if mysql 5 has hierarchical sql? http://www.artfulsoftware.com/mysqlbook/sampler/mysqled1ch20.html PB Thanks. -- No virus found in this outgoing message. Checked by AVG Free Edition. Version: 7.1.394 / Virus Database: 268.8.2/356 - Release Date: 6/5/2006 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Moving database files to larger partition?
I'm currently setting up MySQL 4.1.2 on RHEL 4.1 and I have found the /etc/my.cnf file. I'm trying to find out if I change the basedir from: Basedir=/var/lib To Basedir=/other/path Will that move the actual data files that have all my databases? Do I need to move any of the things that are in /var/lib over to the new path or just the data files of my databases? Thanks! -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Broken Mac pref panel
On Sunday 04 June 2006 20:38, Marcus Bointon scribble on about: On 4 Jun 2006, at 23:25, Marcus Bointon wrote: I'm having trouble with the prefpane in OS X It seems I'm not alone - there are several reports of this in the MySQL bug tracker. Looks like a bug in the prefpane: http://bugs.mysql.com/bug.php?id=19577 In your original message your said that you just installed 5.0.22 (i686). I just upgraded my installation to 5.0.22 as well. However, I didn't update the preference pane software. My preference pane is still working correctly; however, it is from 5.0.20. (Which was a fresh install on a brand new MacBook Pro). So, something may have broken in the lastest software. -- Life may have no meaning, or, even worse, it may have a meaning of which you disapprove. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Moving database files to larger partition?
On 6/5/06, Jay Paulson [EMAIL PROTECTED] wrote: I'm currently setting up MySQL 4.1.2 on RHEL 4.1 and I have found the /etc/my.cnf file. I'm trying to find out if I change the basedir from: Basedir=/var/lib To Basedir=/other/path Will that move the actual data files that have all my databases? Do I need No, MySQL will simply go there looking for files as it starts, if it don't find any, it will crash. MySQL needs at least the mysql database to work. to move any of the things that are in /var/lib over to the new path or just the data files of my databases? If you're not changing versions, move the whole dir (/var/lib/mysql) to the new location, simple as that, but you must do it yourself, cause MySQL won't. -- Daniel da Veiga Computer Operator - RS - Brazil -BEGIN GEEK CODE BLOCK- Version: 3.1 GCM/IT/P/O d-? s:- a? C++$ UBLA++ P+ L++ E--- W+++$ N o+ K- w O M- V- PS PE Y PGP- t+ 5 X+++ R+* tv b+ DI+++ D+ G+ e h+ r+ y++ --END GEEK CODE BLOCK-- -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: procedure analyse() returns bad type?
Hi Gaspar, The following command returns recommended type FLOAT(3,6) for a double(10,6) column: mysql CAT -t -u catadmin -p -e \ select * from temp procedure analyse(16,8192) temp.log Optimal_fieldtype = FLOAT(3,6) NOT NULL. The trouble is that FLOAT(3,6) does not make sense, with FLOAT(M,D), M D+2 should hold. Is procedure analyse(16,8192) old? Or I am doing sth wrong? I have MySQL 5.0.22 under FC3 Linux on AMD64bit. Looks like a bug. The code in question is: if (num_info.dval -FLT_MAX num_info.dval FLT_MAX) sprintf(buff, FLOAT(%d,%d), num_info.integers, num_info.decimals); else sprintf(buff, DOUBLE(%d,%d), num_info.integers, num_info.decimals); It should likely use num_info.integers+num_info.decimals for the M. Regards, Jeremy -- Jeremy Cole MySQL Geek, Yahoo! Inc. Desk: 408 349 5104 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
yum repos for mysql 5.[1] for FC5
Hi all, hate to ask a question that probably has a really obvious answer, but does anyone know of the existence of a mysql 5.1 yum repo that I can point my FC5 box at? -- brendan bouffler Architect, HPC New Technology APJ ESS Competency Lab x: Sydney, Australia, v: +61 404 097 837 mtb: 2003 Tassajara -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
UPDATE from one server to another
I am working on an application where data will be collected on laptops and then uploaded to a central database once the laptop is able to connect to the network after being in the field. I was initially thinking of using MS Access as a front end with linked tables through MySQL ODBC. I am now considering running WAMP on each machine with a web interface because there will be no interoperability issues if MySQL is the db server on both ends, but I am 1.) looking for any recommendations for the laptop interface (MS Access/WAMP or whatever other options might be available) and 2.) want to know what is the actual command for updating a table across two servers (this is NOT replication, but merely updating new data to an existing table). Data transfered will include binary objects and possibly GIS data. For example, Laptop 1 might have 10 rows of data from todays activities that need to be added to the main Server. Laptop 2 might have 30 rows of data that need to be added to the main Server. Neither laptop needs to have the data from the other, but the Server will contain data from both Laptops at the end of the day. The Server will then offer the data through a web interface. Server: Linux/MySQL 5.0 Laptops MS Access 2003 OR MySQL 5.0/ PHP 5/ Apache 2 Thank you. -- Jason -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Security fix for 4.0.27?
Anyone know if 4.0.27 will be fixed for the mysql_real_escape issue? (http://lists.mysql.com/announce/364) 4.1 and 5 have been already, kinda wondering why 4.0 hasn't. Thanks. [EMAIL PROTECTED] __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]