Re: Question
Columns that are UNIQUE or indexed *MUST* be defined as NOT NULL (e.g.: 'nombre INT NOT NULL') Michael On Fri, 3 May 2002, Shows Lycos wrote: Description: error = Column 'nombre' is used with UNIQUE or INDEX but is not defined as NOT NULL My server= mysql Ver 9.38 Distrib 3.22.30, for pc-linux-gnu (i686) Question= Can you help me ? Thanks. Juan - 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 -- /*-- * It might look like I'm doing nothing, but at the cellular level * I'm really quite busy. * ---anonymous * * * -BEGIN GEEK CODE BLOCK- * Version: 3.1 * GCS/P/H/L/O d- s-:-- a26 C++(+++) UL+++$ 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-- --*/ - 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 speed concerns
Technically speaking, TCP/IP communication *is* a form of IPC. IPC isn't restricted to semaphores or message queues, etc. I think that's what he meant (i.e.: mysql client on one box communicating via TCP/IP to a MySQL server on another box). Michael On Wed, 1 May 2002, Gelu wrote: Hi, About at the same IPC(semaphore,share memory,message) i make references too.Are more ways to made a inter process communication mechanism. For example, in my applications i don't use semaphores and messages.This are system functions available from the Kernel. If you type ipcs you can see that mySQL don't use the system functions for inter process communication. My opinion is referencing at, if this CGI (about Shaun said early) retrieve huge data from RDBMS ,sure can create unbalanced processes. For this reason i said it's strongly recommended to setup MySQL on the other host. I have a bad experience with INFORMIX mounted on SCO running in a dual XEON machine.And i think SCO it's more stable than Linux. Of course who use mainframe don't must have any concern. Regards, Gelu _ G.NET SOFTWARE COMPANY Permanent e-mail address : [EMAIL PROTECTED] [EMAIL PROTECTED] - Original Message - From: Svensson, B.A.T. (HKG) [EMAIL PROTECTED] To: Gelu [EMAIL PROTECTED] Cc: Jason Yates [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Wednesday, May 01, 2002 7:32 PM Subject: RE: mysql speed concerns With IPC I mean Inter Process Communication - any process that wants to talk with something else than with it self _needs_ necessarily IPC. Particularly an RDBMS needs IPC - otherwise it is useless. Anyhow. one way one might get faster performance could be to (if possible with the OS) move the swap space from disk into RAM instead. Or even better for speed and response time don't use swap at all! - but then you must know how much RAM memory your system will consume - otherwise you might get into big trouble. It is not impossible to estimate this, but tricky. One way could be to limit number of connections/jobs on the machine, and then assume the worst case scenario from this. -Original Message- From: Gelu Sent: Wednesday, May 01, 2002 6:12 PM To: Svensson, B.A.T. (HKG); Shaun Bramley Cc: Jason Yates; [EMAIL PROTECTED] Subject: Re: mysql speed concerns Hi, MySQL don't seems to use IPC.!?...Strange ..!?...And if Shaun will need real-time response from RDBMS,in my opinion, is strongly recomended to set up MySQL on the other host. Regards, Gelu _ G.NET SOFTWARE COMPANY Permanent e-mail address : [EMAIL PROTECTED] [EMAIL PROTECTED] - Original Message - From: Svensson, B.A.T. (HKG) [EMAIL PROTECTED] To: Shaun Bramley [EMAIL PROTECTED] Cc: Jason Yates [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Wednesday, May 01, 2002 6:20 PM Subject: RE: mysql speed concerns An webserver uses mostly CPU resources while a DB uses I/O, or? Separation between the webserver and the RDBMS also suggest increased delays with IPC. I think one needs to find a balance somewhere in between, and I guess the only way to tell is to actually measure the performance of the system to see what's need to be adjusted in order to get better performance. I would start out by collecting some stats from the RDBMS and the OS, lets say during a weeks time or so, and then just create dummy instances that perform the very same things and slowly increases the load in steps in order to see what happens with the system. file://Anders -Original Message- From: Shaun Bramley [mailto:[EMAIL PROTECTED]] Sent: Wednesday, May 01, 2002 5:13 PM To: Jason Yates; [EMAIL PROTECTED] Subject: Re: mysql speed concerns Hello, The first thing that I would do would be to separate the DB and apache. Set the DB up so that it is on a box of it's own. The system cannot serve pages if it is crunching through the db tables looking for information (and vice versa). Shaun - 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 -- /*-- * It might look like I'm doing nothing, but at the cellular level * I'm really quite busy. * ---anonymous * * * -BEGIN GEEK CODE BLOCK- * Version: 3.1 * GCS/P/H/L/O d-
Re: Not secting empty strings
Hmm. How about: SELECT * FROM tablename WHERE LENGTH(somecolumn) 0 AND ISNULL(othercolumn) != 1 Michael On Mon, 29 Apr 2002, Andrew Kuebler wrote: I want to query records that do not contain empty strings and null values through a SELECT statement. IS NOT NULL works for the nulls, but how I select non-empty strings ()? I tried everything I can think of and even some non-published statements like name IS NOT '' . I just can't figure it out Can anyone help me? Thank you in advance! Andrew - 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 -- /*-- * It might look like I'm doing nothing, but at the cellular level * I'm really quite busy. * ---anonymous * * * -BEGIN GEEK CODE BLOCK- * Version: 3.1 * GCS/P/H/L/O d- s-:-- a26 C++(+++) UL+++$ 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-- --*/ - 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: Changing field size
To my knowledge, nothing would happen to the existing data, since you would be performing a widening conversion. Michael On Sun, 28 Apr 2002, Anthony Rodriguez wrote: I've a VARCHAR(4) field that I want to change to a VARCHAR(6) field. What would happen to the existing data in MySQL db? Thanks! Tony ([EMAIL PROTECTED]) - 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 -- /*-- * It might look like I'm doing nothing, but at the cellular level * I'm really quite busy. * ---anonymous * * * -BEGIN GEEK CODE BLOCK- * Version: 3.1 * GCS/P/H/L/O d- s-:-- a26 C++(+++) UL+++$ 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-- --*/ - 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: problem with libmysqlclient_r.so
For example, have you called mysql_thread_init() before calling mysql_real_connect() in all your threads ? However, to my understanding, mysql_thread_init() is not needed if only one database connection is used, and that database connection is established when the program starts, before any threads have been created. That is, if you call mysql_real_connect() at the top of main(), for example, and you let the connection persist for the lifetime of the program, then mysql_thread_init() is not necessary, and the only thing that you must worry about is to make sure that critical sections (like between mysql_real_query() and mysql_store_result()) are sandwiched in-between a mutex lock. If the above is incorrect, please let me know. Michael On Fri, 26 Apr 2002, Michael Widenius wrote: Hi! Andrey == Andrey Kotrekhov [EMAIL PROTECTED] writes: cut Andrey #12 0x180e7cdc in mysql_real_connect () Andreyfrom /usr/local/mysql/lib/libmysqlclient.so.10 Andrey #13 0x1812f93c in MysqlConnection::real_connect (this=0x80c9c18, Andrey db=0x80fe8b0 zzz, host=0x80fb040 xxx.xxx.xxx, Andrey user=0x80fe910 xxx, passwd=0x80c26aa , port=3306, compress=1, Andrey connect_timeout=60, socket_name=0x80c26be , client_flag=0) Andrey at connection.cc:52 Andrey #14 0x808384f in QueueModule::Run (this=0x80c9c00) at QModule.cc:166 Andrey #15 0x8068a8b in start_Module (ptr=0x80c9c00) at Module.cc:23 Andrey #16 0x181fce73 in _thread_start () from /usr/lib/libc_r.so.4 Andrey #17 0x0 in ?? () Andrey Under FreeBSD gethostbyname is not thread-safe Andrey And there is no thread-safe gethostbyname_r Andrey (function exist but not thread-safe) Andrey Are mysql know about this!!! Sorry but if your OS doesn't support gethostbyname_r(), then mysql_real_connect() is not thread safe (I have just updated our documentation about this) Another issue is that if your client dies in the dbug_ code, this means that you have probably not followed the instructions in the manual section: 'How to Make a Threaded Client' For example, have you called mysql_thread_init() before calling mysql_real_connect() in all your threads ? Regards, Monty -- /*-- * It might look like I'm doing nothing, but at the cellular level * I'm really quite busy. * ---anonymous * * * -BEGIN GEEK CODE BLOCK- * Version: 3.1 * GCS/P/H/L/O d- s-:-- a26 C++(+++) UL+++$ 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-- --*/ - 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: PHP and MySQL help please !
I am not sure if the include statement is design to add mysql BINARIES or SOURCE CODE ?? Neither. It's eventually going to link the final php binary with the mysql shared libraries (probably libmysqlclient). I'm not too familiar with PHP, so I don't know if '--with-mysql=' wants the location of the MySQL root directory (typically /usr/local/mysql for source installations) or the directory that contains the libraries (like above, but /usr/local/mysql/lib). Check to see if /usr/local/mysql exists first. Better yet, try this: find /usr -name libmysqlclient* Hopefully, it will show you the location of one (or more) MySQL client libraries. Start there. Michael On Thu, 25 Apr 2002, Andrew Rich wrote: Fatal Error: Call to undefined function: mysql_connect() in /var/www/html/results.php + I think my PHP does not have mysql included, although I put in the ./configure --with mysql=/usr/local/mysql \ + When I type which mysql it says /usr/bin/msql + So should I put:- ./configure --with-mysql=/usr/local/mysql OR ./configure --with-mysql=/usr/bin/mysql ? I am not sure if the include statement is design to add mysql BINARIES or SOURCE CODE ?? Lost. Andrew -Original Message- From: Andrew Rich [mailto:[EMAIL PROTECTED]] Sent: Thursday, 25 April 2002 11:28 AM To: Andrew Rich; [EMAIL PROTECTED] Subject: RE: PHP and MySQL help please ! Further to this, I removed the @ symbol and got:- Fatal Error: Call to undefined function: mysql_connect() in /var/www/html/results.php @ $db = mysql_pconnect(localhost, user, password); $db = mysql_pconnect(localhost, user, password); Ideas ? Why is it now a undefined function ? Andrew -Original Message- From: Andrew Rich [mailto:[EMAIL PROTECTED]] Sent: Thursday, 25 April 2002 11:14 AM To: [EMAIL PROTECTED] Subject: PHP and MySQL help please ! + PHP Installed and going - I can write to files, retrieve flatfiles + Apache running servers outpages nop probes Trying to talk to SQL using PHP. -- html body h1Go to SQL now/h1 ? echo looking; @ $db = mysql_pconnect(localhost, user, password); if (!$db); { echo Error: Could not connect to database. Please try again later.; exit; } mysql_select_db(test); $query = select * from logbook ; $result = mysql_query($query); $num_results = mysql_num_rows($result); echo pNumber of books found: .$num_results./p; ? /body /html - What gets me if I can do all this from the mysql prompt:- laptopmysql -u user -p (enterpassword gets me in) mysqluse test; OK mysqlselect * from logbook; OK (shows entries no probs); - What am I doing wrong ? It doesnt get past the @ $db = mysql_pconnect(localhost, user, password); in the code. ?? Andrew --- Andrew Rich Callsign: VK4TEC [EMAIL PROTECTED] www.users.bigpond.com/andrew.rich/vk4tec.htm --- Andrew Rich Callsign: VK4TEC [EMAIL PROTECTED] www.users.bigpond.com/andrew.rich/vk4tec.htm - 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 -- /*-- * It might look like I'm doing nothing, but at the cellular level * I'm really quite busy. * ---anonymous * * * -BEGIN GEEK CODE BLOCK- * Version: 3.1 * GCS/P/H/L/O d- s-:-- a26 C++(+++) UL+++$ 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-- --*/ - 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:
MySQL Source Code
Hi all, Does anyone know where I could get all of the source code to build the MySQL software? I wanted to make edits to the SQL language that is embedded in the MySQL software. Is there a way to do that? If not, does anyone have any suggestions on how to do something like that. I want to use SQL Extensions as my thesis topic. Please help. Thanks, Mike. __ Do You Yahoo!? Check out Yahoo! Shopping and Yahoo! Auctions for all of your unique holiday gifts! Buy at http://shopping.yahoo.com or bid at http://auctions.yahoo.com - 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