Re: MySQL (3.23) connection bombardment question ..
i'm just wondering: what hangs first: your scripts or the mysql database? if (one of your) scripts is in a endless loop, for one reason or the other, the symptons will be the same... I would try to figure out if there's one particulair query that hangs, or if it happens randomly. For cgi i wouldn't know what standard behaviour is when a client drops the connection, but i guess you'll have to close the mysql connection yourself. Do your scripts maybe exit on client disconnection without disconnecting to the mysql server? Does your log say anything about connection errors? I'd prefer php scripts anyhow, for speed persistant connections (!), but it is quite tough to rewrite all scripts i'm afraid. gl rene On Fri, 27 Apr 2001 20:45:10 -0400 Terry Katz [EMAIL PROTECTED] wrote: Hello .. I've been experiencing a few problems with MySQL 3.23.3[67] configured for TCP on Linux .. We have two websites which are very active, and are noticing similar behaviour with the database.. One site has about a hundred thousand users, and gets very active a few times a day.. The site does many reads and updates to the database, at the same time .. Usually during the peak times, when it seems as though everyone is logging in and using it, the database starts filling up with queries waiting for updates to complete .. It keeps going until the database server (4 processors @ 550mhz ea) gets unbearably slow, and our cluster of webservers do the same with apache's + cgi's waiting for replies from the database ... From what I've read, this is considered normal, because of the table locking nature of MySQL ... Right? Ok .. The second site does no writes to the database just strictly reads .. The database itself is also on a large server (4 cpu/550mhz), and during peak times where many users bombard the site all at once, the database seems to act similar to above .. Connections flood the system and apache's get caught waiting for a reply .. In both cases the built-in timeouts in MySQL kill the connections, but the scripts (Apache's + cgi's) don't seem to get notified and just hang around indefinately ... This may be a coding bug .. (?) I guess my question is .. Are there any known problems with MySQL receiving many instantaneous connections ? (hundreds within a few seconds .. ) For further info, I'm running linux 2.2.19 configured for up to 2000 processes (the max I've seen the server get to is around 800 .. Idling at around 60)... I've tried running the database with the database both on the local raid and currently over 1gb ethernet to a NetApp filer (incase the local raid, which is a year or so old is too slow .. ) Any ideas? Thanks, Terry Katz - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: MySQL (3.23) connection bombardment question ..
just realised it: another thing might be the linux threading problems. when spawning multiple threads at once, the 2.2 kernel will delay the new threads more and more. Upgrading to kernel 2.4 solves this. read the lists' archives on this, there were several discussions on this subject. regards, rene On Sat, 28 Apr 2001 10:17:26 + Rene Tegel [EMAIL PROTECTED] wrote: i'm just wondering: what hangs first: your scripts or the mysql database? if (one of your) scripts is in a endless loop, for one reason or the other, the symptons will be the same... I would try to figure out if there's one particulair query that hangs, or if it happens randomly. For cgi i wouldn't know what standard behaviour is when a client drops the connection, but i guess you'll have to close the mysql connection yourself. Do your scripts maybe exit on client disconnection without disconnecting to the mysql server? Does your log say anything about connection errors? I'd prefer php scripts anyhow, for speed persistant connections (!), but it is quite tough to rewrite all scripts i'm afraid. gl rene On Fri, 27 Apr 2001 20:45:10 -0400 Terry Katz [EMAIL PROTECTED] wrote: Hello .. I've been experiencing a few problems with MySQL 3.23.3[67] configured for TCP on Linux .. We have two websites which are very active, and are noticing similar behaviour with the database.. One site has about a hundred thousand users, and gets very active a few times a day.. The site does many reads and updates to the database, at the same time .. Usually during the peak times, when it seems as though everyone is logging in and using it, the database starts filling up with queries waiting for updates to complete .. It keeps going until the database server (4 processors @ 550mhz ea) gets unbearably slow, and our cluster of webservers do the same with apache's + cgi's waiting for replies from the database ... From what I've read, this is considered normal, because of the table locking nature of MySQL ... Right? Ok .. The second site does no writes to the database just strictly reads .. The database itself is also on a large server (4 cpu/550mhz), and during peak times where many users bombard the site all at once, the database seems to act similar to above .. Connections flood the system and apache's get caught waiting for a reply .. In both cases the built-in timeouts in MySQL kill the connections, but the scripts (Apache's + cgi's) don't seem to get notified and just hang around indefinately ... This may be a coding bug .. (?) I guess my question is .. Are there any known problems with MySQL receiving many instantaneous connections ? (hundreds within a few seconds .. ) For further info, I'm running linux 2.2.19 configured for up to 2000 processes (the max I've seen the server get to is around 800 .. Idling at around 60)... I've tried running the database with the database both on the local raid and currently over 1gb ethernet to a NetApp filer (incase the local raid, which is a year or so old is too slow .. ) Any ideas? Thanks, Terry Katz - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
ZipSlack 486 installation problems
Hi, I am trying to set up Mysql on the following system (its only a test bed for home useage, for a small scale internet based project) Ideally, this system will be a MySQL, Apache, PHP setup. Low powered I know, but I am assured possible and OK for my purposes Proc: 486 DX2 66 Mem: 40MB HD: 8.4GB Linux: Slackware 7.1- ZipSlack to be more exact MY QUESTION I WOULD LIKE TO KNOW WHAT OTHER USERS RECOMMEND FOR SUCH A SETUP. WHAT VERSIONS TO USE AND SO FORTH. I am having big problems and although I have looked at the scripts etc and changed paths, I can not get the system up and running. I would say I am a beginner at these sysadmin jobs and therefore any advice would be welcome. MY PROBLEMS SO FAR All versions of MySQL I have tried so far have come in RPM format which I have rpm2targz to set up. Then I have gunzip/tar or tar xzf to unpack the archive. The archive unpacks in different folders to those that the scripts expect and this is a problem for a start. Also some files seem to be missing, in particular mysql.sock . In summary, I am not sure if this unpacking process is working correctly and maybe this explains my problems. MYSQL_INSTALL_DB fails to create the grant tables When I setup in an alternative fashion mysql_install_db works, I then find that I can not find the mysql.sock. All advice is welcome.. Duncan - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
select query syntax
i have 400 rows in my mysql database table and i wont get each N row from table (say each sixth row)??? please help me??? - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: select query syntax
supposed you numbered all rows in the table incrementally in field nid: select mydata from mytable where mod(nid, N)=offset; fill in N and offset (0..n-1) On Sat, 28 Apr 2001 14:26:46 +0400 Igor V Yermakov [EMAIL PROTECTED] wrote: i have 400 rows in my mysql database table and i wont get each N row from table (say each sixth row)??? please help me??? - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: Failed to compile.
Eric K. Dickinson writes: All seemed to be going well untill... sr/local/include/mysql -c get_table.cc g++ -O3 -g -pipe -fforce-mem -fforce-addr -I. -I../mysql++-1.7.8/sqlplusint -I/usr/local/include/mysql -c admin.cc g++ -O3 -g -pipe -fforce-mem -fforce-addr -I. -I../mysql++-1.7.8/sqlplusint -I/usr/local/include/mysql -c single.cc g++ -O3 -g -pipe -fforce-mem -fforce-addr -I. -I../mysql++-1.7.8/sqlplusint -I/usr/local/include/mysql -c zoom.cc g++ -O3 -g -pipe -fforce-mem -fforce-addr -I. -I../mysql++-1.7.8/sqlplusint -I/usr/local/include/mysql -c sin_jpeg.cc gcc -O3 -g -pipe -fforce-mem -fforce-addr -I. -I../mysql++-1.7.8/sqlplusint -I/usr/local/include/mysql -c jmemsrc.c jmemsrc.c: In function `jpeg_mem_src': jmemsrc.c:198: warning: assignment from incompatible pointer type gcc -O3 -g -pipe -fforce-mem -fforce-addr -I. -I../mysql++-1.7.8/sqlplusint -I/usr/local/include/mysql -c options.c options.c:17: warning: initialization from incompatible pointer type options.c: In function `mysql_read_default_options': options.c:40: warning: initialization makes pointer from integer without a cast options.c:135: structure has no member named `charset_dir' options.c:136: structure has no member named `charset_dir' options.c:139: structure has no member named `charset_name' options.c:140: structure has no member named `charset_name' make: *** [options.o] Error 1 root@nova:/usr/local/mysqlgui-1.7.4# eric -- Eric K. Dickinson CNE, MCSE, GNU/Linux Geek http://dickinse.dyndns.org NRA Indoor Pistol Master Hi! You are using some ancient MySQL C API libs. Please use latest 3.23 C API. Regards, Sinisa __ _ _ ___ == MySQL AB /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic /*/ /*/ /*/ \*\_ |*| |*||*| mailto:[EMAIL PROTECTED] /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaca, Cyprus /*/ /*/ /*/\*\_/*/ \*\_/*/ |*| /*/^^^\*\^^^ /*/ \*\Developers Team - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: AIX recommendations
Darren Henderson writes: This note is primarily meant to stuff something into the archives in case other people have problems compiling mysql under AIX. There are a number of changes that need to be made that aren't detailed in the documentation, (some alteration to those docs could save someone a lot of effort in the future). I don't know how universal this is so I will say that this works under AIX 4.2.1 for mysql 3.23.37 using gcc 2.95.3 To begin with, you may need to use the following config as opposed to the one given in the docs... CC=gcc -pipe -mcpu=power -Wa,-many \ CXX=gcc -pipe -mcpu=power -Wa,-many \ CXXFLAGS=-felide-constructors -fno-exceptions -fno-rtti \ ./configure --prefix=/usr/local/mysql --with-low-memory The key change here is the -mcpu, the docs specify power2, but that causes compiles on older equipment to toss out bad assembly code. Determine what your cpu is if you are experiencing errors that indicate that problem. Typically power2, power, or powerpc may need to be used, alternatively you might need to use 604 or 604e. I'm not positive but I would think using power would likely be safe most of the time, even on a power2 machine. If you don't know what your cpu is then do a uname -m, this will give you back a string that looks like 000514676700, with a format of xxyymmss where xx and ss are always 0's, yy is a unique system id and mm is the id of the CPU Planar. A chart of these values can be found at http://www.rs6000.ibm.com/doc_link/en_US/a_doc_lib/cmds/aixcmds5/uname.htm This will give you a machine type and a machine model you can use to determine what type of cpu you have. Next, after configuring, edit config.h and change the line that says #define HAVE_SNPRINTF 1 to #undef HAVE_SNPRINTF Do the same for include/my_config.h There is probably a better way to handle that that would address the issue for the entire source but I didn't take the time to find it nor did I stumble across it. And finally, in mysqld.cc you need to add a prototype for initgoups. #ifdef _AIX41 extern C int initgroups(const char *,int); #endif After doing this, I had a version of mysql that I could compile and install. Hopefully there aren't any bugs waiting for me as a result of these changes. I'm seeing test failures for tests rpl15 and rpl16 that I haven't dug into yet but everything else looks ok. Darren Henderson [EMAIL PROTECTED] [EMAIL PROTECTED] Hi! Most of our recommandations are meant for AIX 4.3, not 4.2. Regards, Sinisa __ _ _ ___ == MySQL AB /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic /*/ /*/ /*/ \*\_ |*| |*||*| mailto:[EMAIL PROTECTED] /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaca, Cyprus /*/ /*/ /*/\*\_/*/ \*\_/*/ |*| /*/^^^\*\^^^ /*/ \*\Developers Team - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: Problems with MOD
Roger Ramirez writes: Why do I get the following results? mysql select (1008306000-988344000)/86400/7, mod((1008306000-988344000)/86400,7.); ++-- + | (1008306000-988344000)/86400/7 | mod((1008306000-988344000)/86400,7.) | ++-- + |33.0060 |0 | ++-- + 1 row in set (0.00 sec) Shouldn't the value in Column 2 be some number other then 0? I'm running MySQL 3.23.27. Looks like a bug. Will investigate it. Regards, Sinisa __ _ _ ___ == MySQL AB /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic /*/ /*/ /*/ \*\_ |*| |*||*| mailto:[EMAIL PROTECTED] /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaca, Cyprus /*/ /*/ /*/\*\_/*/ \*\_/*/ |*| /*/^^^\*\^^^ /*/ \*\Developers Team - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
An interesting SELECT problem
I've been creating a site for someone using MySQL and PHP4. Basically the table concerned is structured like this; id int(5) UNSIGNED Noauto_increment Primary ship varchar(50) NoIndex year varchar(15) NoIndex voyage varchar(50) Yes sex varchar(50)Yes notes text Yes Everthing is working fine except the ship order in which the pages are generated. For example, the following are ships names and yes the records do show the voyage date (they are in official records that way and I can change them. I prudently added the year field and the year is put in that field as well. Some ships don't have this date after their name, sometimes they have just a voyage number. Henrietta Henry Henry Porcher Hibernia Hindostan (1) Hindostan (2) Hyderabad (1) Hyderabad (2) Hyderabad (3) Marian Watson (08-06-1842) Marian Watson (28-10-1841) Marion Watson (08-03-1842) Here in lies the problem, these records have been entered at different times so their id's are all over the place When I get these records and display them, they will be in the correct alphanumeric order except for the ones with the date after them. they will only display in the order they were entered. I've tried the following SELECTs $result = mysql_query(SELECT * FROM ships ORDER BY ship,$db) $result = mysql_query(SELECT * FROM ships ORDER BY ship, year,$db) but they dont sort the way we want them to (in year order) as per below Henrietta Henry Henry Porcher Hibernia Hindostan (1) Hindostan (2) Hyderabad (1) Hyderabad (2) Hyderabad (3) Marian Watson (28-10-1841) Marion Watson (08-03-1842) Marian Watson (08-06-1842) Anyone got any ideas? Thanks in advance Howard Picken [EMAIL PROTECTED] -- Database, SQL, Query etc... - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Problem with LAST_INSERT_ID();
Mysql : 3.23.33 server : NT 4.0 S.P.3 Client : Win98 This is the table structure: CREATE TABLE `ordinit` ( `ID_Ordine` int(11) NOT NULL auto_increment, `Cod_Cliente` int(11) default NULL, .. OMISSIS .. PRIMARY KEY (`ID_Ordine`) ) TYPE=MyISAM the query 'select last_insert_id()' after an 'insert' query return always zero. I have tried also with MySQLGUI Client. ( excuse me for my English, it's under construction) Thanks. Best Regards.
myodbc uses bash'ism and should not have #!/bin/sh
Description: The following output occures when using ASH as /bin/sh. Your script seems to rely on non-POSIX features from bash and therefore should be called with #!/bin/bash. This works. -=(~/debian/mysql/ODBC/myodbc2.50.37-2.50.37)$ ./configure creating cache ./config.cache checking for a BSD compatible install... /usr/bin/install -c checking whether build environment is sane... configure: error: ls -t appears to fail. Make sure there is not a broken alias in your environment configure: error: newly created file is older than distributed files! Check your system clock How-To-Repeat: use the smaller (but fully POSIX compliant) /bin/ash as /bin/sh Fix: start the configure script with #!/bin/bash Submitter-Id: submitter ID Originator:Christian Hammers Organization: Debian GNU/Linux MySQL support: none Synopsis: configure relys on bash but uses /bin/sh Severity: non-critical Priority: low Category: myodbc Class: sw-bug Release: myodbc-2.50.37 Server: /usr/bin/mysqladmin Ver 8.19 Distrib 3.23.37, for pc-linux-gnu on i586 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 3.23.37-log Protocol version10 Connection Localhost via UNIX socket UNIX socket /var/run/mysqld/mysqld.sock Uptime: 5 min 51 sec Threads: 1 Questions: 1 Slow queries: 0 Opens: 6 Flush tables: 1 Open tables: 0 Queries per second avg: 0.003 Environment: System: Linux lathspell 2.4.2 #4 Don Feb 22 18:51:59 CET 2001 i586 unknown Architecture: i586 Some paths: /usr/bin/perl /usr/bin/make /usr/local/bin/gmake /usr/bin/gcc /usr/bin/cc GCC: Reading specs from /usr/lib/gcc-lib/i386-linux/2.95.4/specs gcc version 2.95.4 20010319 (Debian prerelease) Compilation info: CC='gcc' CFLAGS='-O2 -fomit-frame-pointer -g' CXX='g++' CXXFLAGS='-O2 -fomit-frame-pointer -g -felide-constructors -fno-exceptions -fno-rtti' LDFLAGS='' LIBC: lrwxrwxrwx1 root root 14 17.04 20:05 /lib/libc.so.5 - libc.so.5.4.46 -rw-r--r--1 root root 567684 13.04 21:14 /lib/libc.so.5.4.46 lrwxrwxrwx1 root root 13 27.03 21:14 /lib/libc.so.6 - libc-2.2.2.so -rwxr-xr-x1 root root 1108076 13.04 16:15 /lib/libc-2.2.2.so -rw-r--r--1 root root 2526954 24.03 08:02 /usr/lib/libc.a -rw-r--r--1 root root 178 24.03 08:02 /usr/lib/libc.so -rw-r--r--1 root root 665260 01.09.2000 /usr/lib/libc-client.so.4.7 Configure command: ./configure --prefix=/usr --exec-prefix=/usr --libexecdir=/usr/sbin --datadir=/usr/share --sysconfdir=/etc/mysql --localstatedir=/var/lib/mysql --includedir=/usr/include --infodir=/usr/share/info --mandir=/usr/share/man --enable-shared --with-libwrap --enable-assembler --with-berkeley-db --with-innodb --enable-static --enable-shared --with-raid --without-readline --with-unix-socket-path=/var/run/mysqld/mysqld.sock --with-mysqld-user=mysql --without-bench --with-extra-charsets=all - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: What is most stable??
Hi! Difficult to say if InnoDB is alpha or beta. You can look at the bugs and fixes diary at my website www.innobase.fi, and form your own opinion. I am committed to fix all bugs you report, and to this day a fix has been available for any bug within 10 days. I have got bug reports from about 20 people. Some seem to use InnoDB under extremely heavy loads. I guess there exist many more testers who have not reported bugs. InnoDB seems to run best on Linux. On FreeBSD and Solaris people have reported more problems. The Windows version should be quite good once MySQL people get it out, since I wrote originally on Windows. In production use the most important thing is to take backups and keep the 'binlog' of MySQL. Customers do not want to lose their data. If you mean by stable that it crashes at most once in a week, I guess that Linux users have got to that position. A crash is not that bad for InnoDB, because it recovers typically in 30 seconds, and no repair procedure needs to be run. I think empirical tests are the best way to determine the stability. And you can change between table types if there are problems. I am happy if you test and use InnoDB. The more bugs people report, the sooner it will be high-quality software. Best regards, Heikki At 04:12 PM 4/27/01 -0700, you wrote: Hello! I am in the process of writing a production web based program for our company. We are going to use MySQL, and wanted to know about the table types. I want transactions if I can get them - how stable is the InnoDB tables? Should I consider them Alpha? or Beta? or is it safe enough for production use? Thanks! Patrick Calkins OEMSupport.Com, Inc. - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Problems with MySQL++
Howdy, I posted this question over on the plusplus list, but so far I've not received a response. This list seems more active, so perhaps someone here can offer me a hand. I'm trying to get the 1.7.8 distribution of MySQL++ to build as directed in the README -- using automake. When I run automake, I get a message saying that Makefile.am is missing some required files: ./INSTALL ./NEWS ./COPYING ./AUTHORS ./ChangeLog Indeed, those don't appear to be in the tar archive. Any ideas? Also, the 1.7.8 distribution (which I got from www.mysql.com) has damaged documentation. It's missing nearly all of the chapter 5 Class reference, as is the online version at the same site. I was able to find complete docs in the separate manual only download. Thanks, --Mike - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
RE: Problems with MySQL++
Howdy, I posted this question over on the plusplus list, but so far I've not received a response. This list seems more active, so perhaps someone here can offer me a hand. I'm trying to get the 1.7.8 distribution of MySQL++ to build as directed in the README -- using automake. When I run automake, I get a message saying that Makefile.am is missing some required files: ./INSTALL ./NEWS ./COPYING ./AUTHORS ./ChangeLog Indeed, those don't appear to be in the tar archive. Any ideas? Do you need them? tar xfz mysql++.tar.gz cd mysql++- ./configure; make; make install Voila. And yes, the mysql online manual has been broken for over 6 months now :) According to mysql people, it will be fixed soon. (Which was something they said.. em.. 5 months ago.) - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: An interesting SELECT problem
I've been creating a site for someone using MySQL and PHP4. Basically the table concerned is structured like this; id int(5) UNSIGNED Noauto_increment Primary ship varchar(50) NoIndex year varchar(15) NoIndex Sir, change the type of this column to Date, which stores the date as -mm-dd. This will allow you to order the records by the date. You can display the date in a different format using Date_format(). Using a 15 character varchar field for data that is exclusively dates and requires a maximum of 10 characters is an invitation for trouble. Also, since the column contains the full date of the voyage, change the name of the column from year (it's not the year, it's the date) to something like sail_date or embarked. voyage varchar(50) Yes sex varchar(50)Yes How do you determine the sex of a voyage? And why does it take 50 characters to specify it? :-) notes text Yes Everthing is working fine except the ship order in which the pages are generated. For example, the following are ships names and yes the records do show the voyage date (they are in official records that way and I can change them. I prudently added the year field and the year is put in that field as well. Some ships don't have this date after their name, sometimes they have just a voyage number. Henrietta Henry Henry Porcher Hibernia Hindostan (1) Hindostan (2) Hyderabad (1) Hyderabad (2) Hyderabad (3) Marian Watson (08-06-1842) Marian Watson (28-10-1841) Marion Watson (08-03-1842) Here in lies the problem, these records have been entered at different times so their id's are all over the place When I get these records and display them, they will be in the correct alphanumeric order except for the ones with the date after them. they will only display in the order they were entered. I've tried the following SELECTs $result = mysql_query(SELECT * FROM ships ORDER BY ship,$db) $result = mysql_query(SELECT * FROM ships ORDER BY ship, year,$db) but they dont sort the way we want them to (in year order) as per below Henrietta Henry Henry Porcher Hibernia Hindostan (1) Hindostan (2) Hyderabad (1) Hyderabad (2) Hyderabad (3) Marian Watson (28-10-1841) Marion Watson (08-03-1842) Marian Watson (08-06-1842) Anyone got any ideas? Thanks in advance Howard Picken [EMAIL PROTECTED] Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection. -Khushhal Khan Khatak MySQL list magic words: sql query database - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: Viewing data from the previous row
Actually, there is a way to do this by taking advantage of variables. If you read my previous post on the matter, you can use variables to get a cumulative total. - Original Message - From: Steve Ruby [EMAIL PROTECTED] To: Roger Karnouk [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Friday, April 27, 2001 12:37 PM Subject: Re: Viewing data from the previous row Roger Karnouk wrote: Is it possible in a Select query to get values from the previously read row in order to do things like cumulative sums or other formulas which require the previous value in order to calculate the current value. ex. day current sales cumu_total - --- 1 120 120 2 60 180 3 125305 4 40 345 I'd like to be able to do this in one select statement is this even possible? Roger Karnouk [EMAIL PROTECTED] Sir, the following works on my machine: SELECT t1.period, t2.sales AS current_sales, Sum(t2.sales) AS cum_total FROM table t1, table t2 WHERE t2. period = t1. period GROUP BY t1. period; Have I ever mentioned the book 'SQL For Smarties' by Joe Celko in any of my previous posts in this mailing list? Bob Hall Know thyself? Absurd direction! Bubbles bear no introspection. -Khushhal Khan Khatak MySQL list magic words: sql query database - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
RE: Problems with MOD
isn't this the expected behavior? (1008306000-988344000)/86400 = 231.04 select mod(231.04,7); 0 231.04 mod 7 is .04, rounded down to 0. 7*33=231 the mod function rounds the result - that's expected, right? Other than that I don't see what the problem is. braxton -Original Message- From: Sinisa Milivojevic [mailto:[EMAIL PROTECTED]] Sent: Saturday, April 28, 2001 7:38 AM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: Problems with MOD Roger Ramirez writes: Why do I get the following results? mysql select (1008306000-988344000)/86400/7, mod((1008306000-988344000)/86400,7.); ++-- + | (1008306000-988344000)/86400/7 | mod((1008306000-988344000)/86400,7.) | ++-- + |33.0060 | 0 | ++-- + 1 row in set (0.00 sec) Shouldn't the value in Column 2 be some number other then 0? I'm running MySQL 3.23.27. Looks like a bug. Will investigate it. Regards, Sinisa __ _ _ ___ == MySQL AB /*/\*\/\*\ /*/ \*\ /*/ \*\ |*| Sinisa Milivojevic /*/ /*/ /*/ \*\_ |*| |*||*| mailto:[EMAIL PROTECTED] /*/ /*/ /*/\*\/*/ \*\|*| |*||*| Larnaca, Cyprus /*/ /*/ /*/\*\_/*/ \*\_/*/ |*| /*/^^^\*\^^^ /*/ \*\Developers Team - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: Problems with MySQL++
Well, cool. If that works I'm happy. I was trying to go by the README and use automake. Thanks! It'd sure be nice if somebody fixed the docs, or at least put a note on the web site that said they're broken. That probably cost me at least a day of confusion. :-( Howdy, I posted this question over on the plusplus list, but so far I've not received a response. This list seems more active, so perhaps someone here can offer me a hand. I'm trying to get the 1.7.8 distribution of MySQL++ to build as directed in the README -- using automake. When I run automake, I get a message saying that Makefile.am is missing some required files: ./INSTALL ./NEWS ./COPYING ./AUTHORS ./ChangeLog Indeed, those don't appear to be in the tar archive. Any ideas? Do you need them? tar xfz mysql++.tar.gz cd mysql++- ./configure; make; make install Voila. And yes, the mysql online manual has been broken for over 6 months now :) According to mysql people, it will be fixed soon. (Which was something they said.. em.. 5 months ago.) - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: What is most stable??
On Fri, Apr 27, 2001 at 04:08:20PM -0700, Patrick Calkins wrote: How stable is InnoDB, BDB, MyISAM, etc?? I am developing a production system using MySQL, and wanted to know that stability status on these table types. I wanted to use transactions if I could - is the transaction-enabled table types stable enough for production? Or should I stick with MyISAM and engineer transaction-like behavior into my code?? If I had to guess based on what I've experienced and what people on this mailing list tend to write, stability is currently related to the age of the code (as it relates to the MySQL project, at least). Of those three, MyISAM is the most stable. In fact, I'd simply say that it is stable. Period. BDB is next, followed by InnoDB. Looking to the future, and this is just my speculation, I suspect that in the next 6-9 months, InnoDB and Gemini (currently in beta) will surpass BDB in terms of stability, quality, and performance. Why? Because they already offer more features and probably better performance than BDB. More folks (who are currently on BDB) will move to them and look back on BDB as the first attempt to get transaction support and more granular locking into MySQL. That's not to say that there's no place in the world for BDB tables. They do provide transactions and page-level locking. Their advantage over InnoDB or Gemini is that they're currently more widely used and they require less administrative setup (though Gemini isn't far behind in this regard). Hope that helps, Jeremy -- Jeremy D. Zawodny, [EMAIL PROTECTED] Technical Yahoo - Yahoo Finance Desk: (408) 349-7878Fax: (408) 349-5454Cell: (408) 439-9951 MySQL 3.23.29: up 115 days, processed 716,984,773 queries (71/sec. avg) - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: New filter
On Sat, Apr 07, 2001 at 10:42:09AM -0600, Sasha Pachev wrote: I have now installed the new spam filter on this list. It is very simple - instead of having bad words, we now have good words. You must mention one of the following: sql, database, query in the body of your message to get past the filter. Substrings are ok, and check is case-insensitive so if you say MySQL, it will work. Having had a few of my posts bounced, I have two questions: (1) Does it count properly separated signatures -- \n as part of the body? (2) Can it be taught to grok a header? Maybe X-MySQL-On-Topic: yes or something? I've already solved my problem if the answer to #1 is yes, but #2 seems like a nice clean and unobtrusive approach. Thanks, Jeremy -- Jeremy D. Zawodny, [EMAIL PROTECTED] Technical Yahoo - Yahoo Finance Desk: (408) 349-7878Fax: (408) 349-5454Cell: (408) 439-9951 MySQL 3.23.29: up 115 days, processed 716,992,956 queries (71/sec. avg) - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
mysql 'top' application
I purchase web space on www.phpwebhosting.com, which offers PHP and mySQL services in a shared server environment. Each user gets their own database, in which they can create their own tables. Today, someone is using a LOT of resources: mysqld is pegged at 96% CPU utilisation, and I'm getting 'running out of connections' errors. How can I tell which user on the system is responsible for the lag? Ideally there would be a command like 'top' that would show which databases are being accessed most frequently, or taking the most time to access. - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: mysql 'top' application
How can I tell which user on the system is responsible for the lag? Ideally there would be a command like 'top' that would show which databases are being accessed most frequently, or taking the most time to access. - Before posting, please check: http://www.mysql.com/manual.php (the manual) Did you check the manual? There's a number of commands to show various information about mysql and various logging options. jason - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Index use, Perl DBI
I have a situation where a query should be using an index, running the query from the mysql terminal using the explain ... command indicates it will use the index, but the actual execution speed tells me the index is not being used: Execution is very slow. I have tried dropping and recreating the index to no avail, and have dropped other indexes that I thought might possibly be confusing the optimizer. No improvement. Is there a way, through the Perl DBI interface, to determine whether a given SELECT query is using indexes? Thank you for any assistance offered. David Keeney David Keeney [EMAIL PROTECTED] Travel By Road http://www.travelbyroad.net - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php