Re: [PHP-DB] Why the sudden dis-interest?
What's with all the people suddenly wanting to unsubscribe? Did they suddenly become experts - no longer needing the community for support? Or did they suddenly discover they had actually enlisted for the influx of emails they were getting and wanted to stop them? Sure seems odd I'll bet they lost interest at some point, but never bothered figuring out how to unsubscribe, and then saw one man (OP of that thread) have the nerve to ask publicly, please unsubscribe me, and they thought, ah, perfect opportunity to jump on that bandwagon, and so save save from having to be the lone odd public case, AND not have to figure how to do it myself. Just a guess. -Govinda -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why the sudden dis-interest?
I am happy with this community. I get a lot of new things to learn daily. On Fri, Sep 21, 2012 at 10:07 AM, Jim Giner jim.gi...@albanyhandball.comwrote: What's with all the people suddenly wanting to unsubscribe? Did they suddenly become experts - no longer needing the community for support? Or did they suddenly discover they had actually enlisted for the influx of emails they were getting and wanted to stop them? Sure seems odd -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why the sudden dis-interest?
I feel the same, I'm happy to receive all this emails as sometimes I'm able to help them and I learn new things Jey -- -Original Message- From: Rikin Parekh riki...@gmail.com Date: Fri, 21 Sep 2012 14:14:03 To: jim.gi...@albanyhandball.com Cc: php-db@lists.php.net Subject: Re: [PHP-DB] Why the sudden dis-interest? I am happy with this community. I get a lot of new things to learn daily. On Fri, Sep 21, 2012 at 10:07 AM, Jim Giner jim.gi...@albanyhandball.comwrote: What's with all the people suddenly wanting to unsubscribe? Did they suddenly become experts - no longer needing the community for support? Or did they suddenly discover they had actually enlisted for the influx of emails they were getting and wanted to stop them? Sure seems odd -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why the sudden dis-interest?
Some of them may not end up being PHP + DB programmers? Or joined under mistaken expectations? Or thought it might be a good idea at the time and ended up doing something else? Lots of possible reasons. Given the inability of the folk to figure out *how* to unsubscribe, I'd suspect rather limited understanding of internet technology to begin with. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why the sudden dis-interest?
On Friday, September 21, 2012 10:07:56 AM Jim Giner wrote: What's with all the people suddenly wanting to unsubscribe? Did they suddenly become experts - no longer needing the community for support? Or did they suddenly discover they had actually enlisted for the influx of emails they were getting and wanted to stop them? Sure seems odd I'm still here. I mostly linger in the background until there's an opportunity where I could help and I also try to figure things out on my own before asking the list. I find that the information stick to me better when I find the answer myself. Good ol blood sweat and tears. :-) -- David M. David's Webhosting and consulting.
Re: [PHP-DB] Why $row is EMPTY
I could be wrong, but I don't think table aliases continue to exist in PHP; only the column names. $g_name = $row[gigName]; $vname = $row[venueName]; $genre = $row[name]; You may also consider revising the query to only grab the columns you need, using an alias for at least genre.name. $query = 'SELECT gig.gigName AS gig, venue.venueName AS venue, genre.name AS genre FROM `gig` LEFT JOIN genre ON gig.genreId=genre.genreId LEFT JOIN venue ON gig.venueID = venue.vid where gig.gigid = '.$gigDetail.' ORDER BY gig.gigid'; $result = mysql_query($query) or die(mysql_error()); while ($row = mysql_fetch_array($result)) { echo Program is in While loop; $g_name = $row[gig]; $vname = $row[venue]; $genre = $row[genre]; echo(Gig Name: .$g_name); } - Jon L. On Tue, Apr 29, 2008 at 1:27 PM, Nasreen Laghari [EMAIL PROTECTED] wrote: Hi, Why my program is not going in while loop? When I run the same query in SQL cmd, it brings result but here when I print $result gives Resouce ID number means $result has data then why $row is empty. $query = 'SELECT * FROM `gig` LEFT JOIN genre ON gig.genreId=genre.genreId LEFT JOIN venue ON gig.venueID = venue.vid where gig.gigid = '.$gigDetail.' ORDER BY gig.gigid'; $result = mysql_query($query) or die(mysql_error()); while ($row = mysql_fetch_array($result)) { echo Program is in While loop; $g_name = $row[gig.gigName]; $vname = $row[venue.venueName]; $genre = $row[genre.name]; echo(Gig Name: .$g_name); } Regards Nasreen Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
Re: [PHP-DB] Why $row is EMPTY
Try doing print_r($row); in your while loop and see what exactly is in that array. Ken On Tue, Apr 29, 2008 at 1:46 PM, Jon L. [EMAIL PROTECTED] wrote: I could be wrong, but I don't think table aliases continue to exist in PHP; only the column names. $g_name = $row[gigName]; $vname = $row[venueName]; $genre = $row[name]; You may also consider revising the query to only grab the columns you need, using an alias for at least genre.name. $query = 'SELECT gig.gigName AS gig, venue.venueName AS venue, genre.name AS genre FROM `gig` LEFT JOIN genre ON gig.genreId=genre.genreId LEFT JOIN venue ON gig.venueID = venue.vid where gig.gigid = '.$gigDetail.' ORDER BY gig.gigid'; $result = mysql_query($query) or die(mysql_error()); while ($row = mysql_fetch_array($result)) { echo Program is in While loop; $g_name = $row[gig]; $vname = $row[venue]; $genre = $row[genre]; echo(Gig Name: .$g_name); } - Jon L. On Tue, Apr 29, 2008 at 1:27 PM, Nasreen Laghari [EMAIL PROTECTED] wrote: Hi, Why my program is not going in while loop? When I run the same query in SQL cmd, it brings result but here when I print $result gives Resouce ID number means $result has data then why $row is empty. $query = 'SELECT * FROM `gig` LEFT JOIN genre ON gig.genreId=genre.genreId LEFT JOIN venue ON gig.venueID = venue.vid where gig.gigid = '.$gigDetail.' ORDER BY gig.gigid'; $result = mysql_query($query) or die(mysql_error()); while ($row = mysql_fetch_array($result)) { echo Program is in While loop; $g_name = $row[gig.gigName]; $vname = $row[venue.venueName]; $genre = $row[genre.name]; echo(Gig Name: .$g_name); } Regards Nasreen Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why $row is EMPTY
Nasreen Laghari wrote: Hi, Why my program is not going in while loop? When I run the same query in SQL cmd, it brings result but here when I print $result gives Resouce ID number means $result has data then why $row is empty. No, it means the query worked. If it wasn't a resource it would be false (eg an sql error). See how many rows are returned: echo mysql_num_rows($result); What does that query return when you run it outside of php? -- Postgresql php tutorials http://www.designmagick.com/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] Why does this code/query hang time out ?
... inline ... for ease: At 23:53 31/03/2005, Juffermans, Jos wrote: So far, I have found a few mistakes in your SQL: $query .= OR `variant` LIKE '%.$_GET['search'].%'; Why do you have backtick-quotes around variant? Know that backticks are used to call system commands. You also use these backticks in the ORDER BY lines. My guess is the backticks are causing your problems. Because they have to be there for MySQL to understand the query ? I sometimes have field names where part of the name is the same as a command, so without the ticks MySQL can't understand the queries. They're actually in the documentation for MySQL, so I don't get why it would cause problems. I always use them, and when I don't, I have problems. And the ORDER clause DOESN'T WORK without them... ever, when I try to do without them and have more than order clause. $query .= AND make.makeID='.$_GET['make'].'; ... $query .= AND make.makeID0; If make.makeID is a number field, why is the value in quotes for the cases where $_GET['make'] is set? Same with socket.socketID a few lines down. Because it doesn't matter, function-wise, if they're there or not for numbers. And it's easier and faster to just put them in for everything, than remembering to exclude them for numeric fields, and include them for non-numeric. Yeah, it takes MySQL a little longer to have to convert from text to number and such, but it's a microscopic amount of time. Unrelated but very important, putting form variables (either GET or POST) directly into a query is dangerous. If I create a copy of your form and fill $_GET['search'] with eg: a%';DELETE * FROM model;SELECT * FROM model WHERE something LIKE '%a Your query will be like this: SELECT .. FROM WHERE AND model.modelName LIKE '%a%';DELETE * FROM model;SELECT * FROM model WHERE something LIKE '%a OR VARIANT You can't trust incoming variables. Yeah, I know ... this code was from before I learned how to check and escape form fields though, just didn't put the error checking/correction into the code yet ... haven't worked on this thing for like a year cuz I got sick of it after putting the several hundred rows manually into the database. I wrote this script originally before I knew anything about using relational tables in SQL, I simply just changed the query code to use the relations instead, and that's when it died. That said, the query worked when being put directly into a MySQL prompt, albeit extremely slow and far beyond what's normal. But I gave up trying to fix it as I couldn't find the problem, so I dumped the entire query part of the code, and started over with new code, from another script that uses the same tables, but have never caused me any problems ... and it works now. And almost 10 times faster than before. It can pull the entire 882 rows, and generate the entire page, in 12 seconds. And all I did was use a different query as basis, write completely new query generating code from scratch, and add some functionality to the form ... I haven't added the LIKE part to the new code, but I've changed the field select boxes to multi-select instead of single-select, and the order picking now lets you choose 3 orders, instead of just 1, so the code's a bit different now. I know it looks like it does some double-checking of the same thing, but it's to be damn sure it doesn't run the code parts unless it has to. And the code works, and much, much faster than the old one. In fact it takes it longer to ship the data over my network than it takes the server to run the script. I don't get why it's so much faster now, as there's very little difference in the query, but it does, and it's all I really wanted. It still needs some fine-tuning to handle the addslashes and such, but I haven't gotten to it yet. // array holding possible fields for sorting. It's used in 3 drop-downs in the query form. $arrsort = array('Make','Model','Variant','Clock','Multiplier','FSB','FSBx','L1','L2','L3','Vcore','Vcache','Socket/Slot'); if ($_POST['do'] == 'search') { $filterwhere = ''; if (! empty($_POST['make'])) { if (is_array($_POST['make'])) { $arrmake = array_values($_POST['make']); if (! in_array('all',$arrmake)) { if (count($arrmake) 1) { $filterwhere = cpu_maker.makeID IN('.implode(',',$arrmake).') AND; } else { $filterwhere = cpu_maker.makeID='{$arrmake[0]}' AND; } } } } if (! empty($_POST['socket'])) { if (is_array($_POST['socket'])) { $arrsocket = array_values($_POST['socket']); if (! in_array('all',$arrsocket)) { if (count($arrsocket) 1) { $filterwhere .= cpu_socket.socketID IN('.implode(',',$arrsocket).') AND; } else { $filterwhere .= cpu_socket.socketID='{$arrsocket[0]}' AND; } } } } $filterorder = ''; for ($i = 0; $i 3; $i++) { $num = $i+1; $sort = 'sort'.$num;
RE: [PHP-DB] Why does this code/query hang time out ?
i Rene, So far, I have found a few mistakes in your SQL: $query .= OR `variant` LIKE '%.$_GET['search'].%'; Why do you have backtick-quotes around variant? Know that backticks are used to call system commands. You also use these backticks in the ORDER BY lines. My guess is the backticks are causing your problems. $query .= AND make.makeID='.$_GET['make'].'; ... $query .= AND make.makeID0; If make.makeID is a number field, why is the value in quotes for the cases where $_GET['make'] is set? Same with socket.socketID a few lines down. Unrelated but very important, putting form variables (either GET or POST) directly into a query is dangerous. If I create a copy of your form and fill $_GET['search'] with eg: a%';DELETE * FROM model;SELECT * FROM model WHERE something LIKE '%a Your query will be like this: SELECT .. FROM WHERE AND model.modelName LIKE '%a%';DELETE * FROM model;SELECT * FROM model WHERE something LIKE '%a OR VARIANT You can't trust incoming variables. Jos -Original Message- From: -{ Rene Brehmer }- [mailto:[EMAIL PROTECTED] Sent: 31 March 2005 23:43 To: php-db@lists.php.net Subject: [PHP-DB] Why does this code/query hang time out ? Hi gang My CPU database (http://metalbunny.net/computers/cpudb.php) - still a work in progress - used to be in 1 table, but for several reasons I've decided it's better to split the data into multiple related tables. Obviously this means I have to rewrite the query tool for it, and that's where my problem lies. I've included the code I'm working with below, it's a little different than the one for the above URL, as it uses my new faster templates and relies more on the database than the old code did. All the DB connect stuff is in the template, and I use MySQL. The new version isn't available online, it's only on my local development server. I'm pretty sure it's simply a coding problem, but for the life of me I can't find anything that looks wrong ... but then I've been staring at it for hours... My problem came after I tried making it possible to pick 'all' as a search option in make model, and now, nomatter whether it's set to all or not, and nomatter what's in the search field, the code stalls and hangs ... and in the last tries, Firefox ended up closing down ... I tried putting athlon in the search box, and just leave everything on default, and the generated query looks like this: SELECT make.makeID,makeName,model.modelID,modelName,fsb2,socket.socketID,socketName ,cpuID,variant,clock,multi,fsb,l1,l2,l3,vcore,vcache FROM cpu_maker AS make,cpu_model AS model,cpu_socket AS socket,cpu_cpus AS cpu WHERE make.makeID=model.makeID AND socket.socketID=model.socketID AND cpu.modelID=model.modelID AND model.modelName LIKE '%athlon%' OR `variant` LIKE '%athlon%' AND make.makeID0 AND socket.socketID0 Leaving the search box empty produces no result - it's an unintended leftover from the old code that I haven't found a good way to get around yet. The code I'm working on looks like this (beware, it's rather long): ?php // load dependencies require('../include/sql.php'); // set data for template $section = 'tools'; $style2 = 'cputables.css'; $title = 'CPU Database'; $menu = true; // begin to build query string $query = 'none'; $basequery = 'SELECT make.makeID,makeName,model.modelID,modelName,fsb2,socket.socketID,socketName ,cpuID,variant,clock,multi,fsb,l1,l2,l3,vcore,vcache FROM cpu_maker AS make,cpu_model AS model,cpu_socket AS socket,cpu_cpus AS cpu WHERE make.makeID=model.makeID AND socket.socketID=model.socketID AND cpu.modelID=model.modelID'; // part 1, search parameters if (! empty($_GET['search'])) { $query = $basequery; $setorder = true; $query .= AND model.modelName LIKE '%.$_GET['search'].%'; $query .= OR `variant` LIKE '%.$_GET['search'].%'; if ($_GET['make'] != 'all') { $query .= AND make.makeID='.$_GET['make'].'; } else { $query .= AND make.makeID0; } if ($_GET['socket'] != 'all') { $query .= AND socket.socketID='.$_GET['socket'].'; } else { $query .= AND socket.socketID0; } $linkquery = substr($_SERVER['QUERY_STRING'],0,strpos($_SERVER['QUERY_STRING'], 'order')); } // part 2, sort order if ($setorder) { switch ($_GET['order']) { case 'socket': $query .= ' ORDER BY `socketName`'; break; case 'vcache': $query .= ' ORDER BY `vcache`'; break; case 'vcore': $query .= ' ORDER BY `vcore`'; break; case 'l2': $query .= ' ORDER BY `l2`'; break; case 'l1': $query .= ' ORDER BY `l1`'; break; case 'fsb': $query .= ' ORDER BY `fsb`'; break; case 'multi': $query .= ' ORDER BY `multi`'; break; case 'clock': $query .= ' ORDER BY `clock`'; break; case 'variant': $query .= ' ORDER BY `variant`'; break;
Re: [PHP-DB] Why not ?
Why does this NOT work? UPDATE tipping SET score = 3 WHERE round1.game1 = H AND tipping.username = jerry; For starters, you should quote strings in a query. There may also be a problem with the round1 reference. Larry -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why not ?
JeRRy wrote: Why does this NOT work? UPDATE tipping SET score = 3 WHERE round1.game1 = H AND tipping.username = jerry; Please inform? You're not linking table round1 to table tipping in any way, and you've got some quoting issues. something like this: UPDATE tipping SET score=3 WHERE round1.game1='H' AND round1.username=tipping.username AND tipping.username='jerry'; cheers, -- - Martin Norland, Sys Admin / Database / Web Developer, International Outreach x3257 The opinion(s) contained within this email do not necessarily represent those of St. Jude Children's Research Hospital. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why not ?
--- Larry E. Ullman [EMAIL PROTECTED] wrote: Why does this NOT work? UPDATE tipping SET score = 3 WHERE round1.game1 = H AND tipping.username = jerry; For starters, you should quote strings in a query. There may also be a problem with the round1 reference. Larry I was getting an error earlier stating round1 does not exist, however it does. round1 table does not exist. So does not say round1.game1 does not exist. But the table name exists. And I use the correct quotations, this does not effect it without it when i use other queries. I will keep trying... If anyone knows, shoot! :) J Find local movie times and trailers on Yahoo! Movies. http://au.movies.yahoo.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] Why not ?
missing single quotes around text UPDATE tipping SET score = 3 WHERE round1.game1 =' H' AND tipping.username = 'jerry'; bastien From: JeRRy [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] Why not ? Date: Fri, 25 Mar 2005 04:05:28 +1100 (EST) Why does this NOT work? UPDATE tipping SET score = 3 WHERE round1.game1 = H AND tipping.username = jerry; Please inform? J Find local movie times and trailers on Yahoo! Movies. http://au.movies.yahoo.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why not ?
On Thursday 24 March 2005 17:26, JeRRy wrote: I was getting an error earlier stating round1 does not exist, however it does. round1 table does not exist. So does not say round1.game1 does not exist. Does a table named round1 exist in your database? If so and you are using mysql 4.0.4 you will need to mention all tables referenced in the WHERE clause in the UPDATE clause. e.g. UPDATE tipping, round1 SET tipping.score = 3 WHERE round1.game1 = 'H' AND tipping.username = 'jerry' (assuming the score column you want to update is in the tipping table...) You almost certainly want to join the two tables as well but without knowing your database it is impossible for me to say how. If you are using an older mysql version what you want to do is probably impossible in one statement. Simon -- ~~ Simon Rees | [EMAIL PROTECTED] | ORA-03113: end-of-file on communication channel ~~ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why isn't this working?
Chris Payne wrote: Hi everyone, Im trying to split a string by comma, but its not working, can you see any reason that the below doesnt work? $keywords = preg_split(',','$Agent_Rep'); Not sure why you sent this to php-db, but have another look at the preg_split documentation. You need '/,/' there to split on a comma. -Rasmus -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why isn't this working?
For more efficient code try the explode() function (You really only want to use the regular expression functions for complex pattern matching, looking for a comma is about as simple as it gets so use the standard string functions) explode (',',$Agent_Rep); graeme. Rasmus Lerdorf wrote: Chris Payne wrote: Hi everyone, Im trying to split a string by comma, but its not working, can you see any reason that the below doesnt work? $keywords = preg_split(',','$Agent_Rep'); Not sure why you sent this to php-db, but have another look at the preg_split documentation. You need '/,/' there to split on a comma. -Rasmus -- Experience is a good teacher, but she sends in terrific bills. Minna Antrim -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] why is it so?
session_start() needs to be the first piece of code at the top of the page, you must have something else before it. ?php session_start() // all php code follows ? -Original Message- From: Nayyar Ahmed [mailto:[EMAIL PROTECTED] Sent: Thursday, December 30, 2004 10:56 AM To: php-db@lists.php.net Subject: [PHP-DB] why is it so? Hello All, I am unable to understand when I execute etc.php, it give me the error Warning: session_start(): Cannot send session cache limiter - headers already sent . can you solve this leral ? TIA -- Nayyar Ahmad Lecturer Faculty Of Computer Science, Institute Of Management Sciences, Hayat Abad Peshawar , Pakistan. Office : 92-091-9217404 , 9217452 Cell : 92-0333-9139461 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] why is it so?
in this page somwhere, or perhaps in an include, there is a blank space or some html echoed out to the page bastien From: Nayyar Ahmed [EMAIL PROTECTED] Reply-To: Nayyar Ahmed [EMAIL PROTECTED] To: php-db@lists.php.net Subject: [PHP-DB] why is it so? Date: Thu, 30 Dec 2004 20:56:21 +0500 Hello All, I am unable to understand when I execute etc.php, it give me the error Warning: session_start(): Cannot send session cache limiter - headers already sent . can you solve this leral ? TIA -- Nayyar Ahmad Lecturer Faculty Of Computer Science, Institute Of Management Sciences, Hayat Abad Peshawar , Pakistan. Office : 92-091-9217404 , 9217452 Cell : 92-0333-9139461 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] Why does this conditional run, even if not true?
Bastien, Thanks for your reply (and on the weekend, no less!). I went back and looked and the function does return only YES or NO so that wasn't the problem. What I found to be the problem was that my while loop inside the IF clause was running no matter what. So what I did was put the while loop in it's own function and voila! no more problems. PHP is funny. It seems to trip on it's own shoestrings sometimes. (either that or I didn't RTFM) :) Cheers, Karen Bastien Koert [EMAIL PROTECTED] wrote: hard to say without the code for the function...what is returned by the fuction determines if the code runs, right? Are you sure the code is returning YES? Maybe post the code for the function bastien From: Karen Resplendo To: [EMAIL PROTECTED] Subject: [PHP-DB] Why does this conditional run, even if not true? Date: Fri, 8 Oct 2004 18:33:02 -0700 (PDT) $c is a field in an array I have loaded in from a text file. For some reason, none of the conditionals branch off and I end up printing out error messages for every row in the text file. My brackets are balanced, I just didn't include the bottom part: If ($c==9) { If($fieldarray[3]==P) { $reject=validate($fieldarray[0],$c,$connectionSDWIS, $fieldarray[$c],$c); This If statement runs even if $reject = YES. Can't figure out why: if ($reject==NO) { // //loop through the rows in the this text file checking for Original ID of Repeat // $handle2 = fopen ($uploadfileandpath,r); while ($field2array = fgetcsv ($handle2, $userfile_size, ,)) { If($field2array[2]!=$fieldarray[$c]) { echo Field 2 of array 2 text row: .$field2array[2]. ; echo Field 9 of array 1 text row: .$fieldarray[$c]. ; $acceptOrReject = R; $displayrows.=See below: Original Sample ID for Repeat does not exist : .$fieldarray[$c]. ; } } //end of while loop fclose($handle2); }//end of If($reject ==No) - Do you Yahoo!? Yahoo! Mail Address AutoComplete - You start. We finish. _ Don't just Search. Find! http://search.sympatico.msn.ca/default.aspx The new MSN Search! Check it out! - Do you Yahoo!? vote.yahoo.com - Register online to vote today!
RE: [PHP-DB] Why does this conditional run, even if not true?
hard to say without the code for the function...what is returned by the fuction determines if the code runs, right? Are you sure the code is returning YES? Maybe post the code for the function bastien From: Karen Resplendo [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: [PHP-DB] Why does this conditional run, even if not true? Date: Fri, 8 Oct 2004 18:33:02 -0700 (PDT) $c is a field in an array I have loaded in from a text file. For some reason, none of the conditionals branch off and I end up printing out error messages for every row in the text file. My brackets are balanced, I just didn't include the bottom part: If ($c==9) { If($fieldarray[3]==P) { $reject=validate($fieldarray[0],$c,$connectionSDWIS, $fieldarray[$c],$c); This If statement runs even if $reject = YES. Can't figure out why: if ($reject==NO) { // //loop through the rows in the this text file checking for Original ID of Repeat // $handle2 = fopen ($uploadfileandpath,r); while ($field2array = fgetcsv ($handle2, $userfile_size, ,)) { If($field2array[2]!=$fieldarray[$c]) { echo brField 2 of array 2 text row: .$field2array[2].br; echo brField 9 of array 1 text row: .$fieldarray[$c].br; $acceptOrReject = R; $displayrows.=font color=redbSee below: Original Sample ID for Repeat does not exist : .$fieldarray[$c]./b/fontbr; } } //end of while loop fclose($handle2); }//end of If($reject ==No) - Do you Yahoo!? Yahoo! Mail Address AutoComplete - You start. We finish. _ Don't just Search. Find! http://search.sympatico.msn.ca/default.aspx The new MSN Search! Check it out! -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] WHY need to query 2x to get results
Because you have already fetched one row before outputting the record count. Therefore the row pointer is at the second record before you 'print out'. Try putting mysql_data_seek($result,0); in place of your second $result = mysql_query($sql); This should return the pointer to the first retreived record. Hope that helps Terry --Original Message- Hi, I have a code that goes like this. Scroll down to the -- sign. How come I need another $result = mysql_query($sql) at that location? If I don't have it, the results coming out will only start printing from the 2nd Row.. Omitting the 1st. Results as wanted row 1 value1 row 2 value2 row 3 value3 Getting this instead row 2 value2 row 3 value3 Pls Help. $result = mysql_query($sql); $num_results = mysql_num_rows($result); $row = mysql_fetch_row($result); echo 'ph4There are ' . $num_results; echo ' FA entries found/p/h4' . \n; echo 'table border=2 cellpadding=5' . \n; echo 'td colspan=' . sizeof($row) . ' align=center '; echo '/td' . \n; # === # Print out the Table Field Names # === echo '!-- Results Table Header Field Names --'; echo \n; echo 'tr' . \n; for ($k = 0; $k sizeof($row) ; $k++) { echo \t . 'td'; echo mysql_field_name($result,$k); echo /td \n; } # === # Print out the Table Results # === $result = mysql_query($sql); ---==WHY Is THIS needed for ($i = 0; $i $num_results ; $i++) { echo tr\n ; $row = mysql_fetch_row($result); for ($j = 0; $j 12 ; $j++) { echo \t . 'td'; echo $row[$j] ; echo /td \n; } echo /tr\n; } Cheers, Mun Heng, Ow H/M Engineering Western Digital M'sia DID : 03-7870 5168 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] why script only updating one table? SOLVED
Hi Guys, No need to think about this. I solved the problem by putting both scripts under one check If ($patternThreads || $patternFabrics) { //DO STUFF HERE } Aaron -Original Message- From: Aaron Wolski [mailto:[EMAIL PROTECTED] Sent: July 22, 2003 10:34 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] why script only updating one table? Hi All, I have a form that passes to select box array to my script. Select boxes are named: patternThreads[] and patternFabrics[] My Script: //Check to see if Threads were selected for this pattern if ($patternThreads) { if (is_array($patternThreads)) { $str_threads = implode(,,$patternThreads); } else { $str_threads = $patternThreads; } $threadsArray = explode(,,$str_threads); for ($i=0;$isizeof($threadsArray);$i++) { //Grab a listing of all threads currently in the DB //associated with the pattern $allthreadsQuery = db_query(SELECT id FROM kcs_patternthreads WHERE pattern_index='$id' AND thread_index=.escapeValue($threadsArray[$i])); //Does a record already exist? if (db_numrows($allthreadsQuery) 1) { //No? Insert a new record for each new keyword selected db_query(INSERT INTO kcs_patternthreads (id,pattern_index,thread_index,avail) VALUES ('','$id',.escapeValue($threadsArray[$i]).,'0')); } } //Check to see if a thread was unchecked. //If so, delete entry from DB $db_threads1 = db_query(SELECT * FROM kcs_patternthreads WHERE pattern_index='$id'); while($db_threads2 = db_fetch($db_threads1)) $db_threads[] = $db_threads2[thread_index]; foreach($db_threads AS $thread) { if(!in_array($thread, $threadsArray)) db_query(DELETE FROM kcs_patternthreads WHERE pattern_index='$id' AND thread_index='$thread'); } } //Check to see if fabrics were selected for this pattern if ($patternFabrics) { if (is_array($patternFabrics)) { $str_fabrics = implode(,,$patternFabrics); } else { $str_fabrics = $patternFabrics; } $fabricsArray = explode(,,$str_fabrics); for ($i=0;$isizeof($fabricsArray);$i++) { //Grab a listing of all fabrics currently in the DB //associated with the pattern $allfabricsQuery = db_query(SELECT id FROM kcs_patternfabrics WHERE pattern_index='$id' AND fabric_index=.escapeValue($fabricsArray[$i])); //Does a record already exist? if (db_numrows($allfabricsQuery) 1) { //No? Insert a new record for each new keyword selected db_query(INSERT INTO kcs_patternfabrics (id,pattern_index,fabric_index,avail) VALUES ('','$id',.escapeValue($fabricsArray[$i]).,'0')); } } //Check to see if a fabric was unchecked. //If so, delete entry from DB $db_fabrics1 = db_query(SELECT * FROM kcs_patternfabrics WHERE pattern_index='$id'); while($db_fabrics2 = db_fetch($db_fabrics1)) $db_fabrics[] = $db_fabrics2[fabric_index]; foreach($db_fabrics AS $fabric) { if(!in_array($fabric, $fabricsArray)) db_query(DELETE FROM kcs_patternfabrics WHERE pattern_index='$id' AND fabric_index='$fabric'); } } The scrip is supposed to see if either select box contains data and then process the data. Does anyone understand why it would be updating only one table at a time and not both at the same time? It should be updating both at the same time! NOTE: if I remove the processing code for either select box it works without problem. They just don't seem to work together. Thanks! Aaron -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] WHY need to query 2x to get results
It worked like a charm. (initially I was trying to use reset() guess it was the wrong call) One other thing, The 1st call was supposed to get the Column Headers and the second to get the results. I thought they are independent of each other?? Guess not? thanks very much. Cheers, Mun Heng, Ow H/M Engineering Western Digital M'sia DID : 03-7870 5168 -Original Message- From: Terry Riley [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 22, 2003 7:33 PM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] WHY need to query 2x to get results Because you have already fetched one row before outputting the record count. Therefore the row pointer is at the second record before you 'print out'. Try putting mysql_data_seek($result,0); in place of your second $result = mysql_query($sql); This should return the pointer to the first retreived record. Hope that helps Terry --Original Message- Hi, I have a code that goes like this. Scroll down to the -- sign. How come I need another $result = mysql_query($sql) at that location? If I don't have it, the results coming out will only start printing from the 2nd Row.. Omitting the 1st. Results as wanted row 1 value1 row 2 value2 row 3 value3 Getting this instead row 2 value2 row 3 value3 Pls Help. $result = mysql_query($sql); $num_results = mysql_num_rows($result); $row = mysql_fetch_row($result); echo 'ph4There are ' . $num_results; echo ' FA entries found/p/h4' . \n; echo 'table border=2 cellpadding=5' . \n; echo 'td colspan=' . sizeof($row) . ' align=center '; echo '/td' . \n; # === # Print out the Table Field Names # === echo '!-- Results Table Header Field Names --'; echo \n; echo 'tr' . \n; for ($k = 0; $k sizeof($row) ; $k++) { echo \t . 'td'; echo mysql_field_name($result,$k); echo /td \n; } # === # Print out the Table Results # === $result = mysql_query($sql); ---==WHY Is THIS needed for ($i = 0; $i $num_results ; $i++) { echo tr\n ; $row = mysql_fetch_row($result); for ($j = 0; $j 12 ; $j++) { echo \t . 'td'; echo $row[$j] ; echo /td \n; } echo /tr\n; } Cheers, Mun Heng, Ow H/M Engineering Western Digital M'sia DID : 03-7870 5168 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Why do these values not match?
Any idea why this problem does not manifest itself in Foxpro, Excel or Visual Basic? Pierre-Alain Joye wrote:On Tue, 25 Jun 2002 18:14:13 -0700 wrote: IEEE standard is precision to 6 decimal places. Having an epsilon of 2 is ridiculously small, and well under the IEEE / ANSI standard. While floats should never be directly compared as a matter of course, in this instance it's a bit silly. Never test equality with two floats,this is a rule in ANSI C too, not directly the standard, but a well known fact. And this fact is one in many langages. Try a test with mysql :). I will not continue discussions about bugs or not, that has been already discussed many times :) check the archives. hth hth pa ~ Manuel Ochoa ~ Seven days is too long to wait for a gun! - Do You Yahoo!? Sign-up for Video Highlights of 2002 FIFA World Cup
Re: [PHP-DB] Why do these values not match?
On Wed, 26 Jun 2002 06:52:14 -0700 (PDT) Manuel [EMAIL PROTECTED] wrote: Any idea why this problem does not manifest itself in Foxpro, Excel or Visual Basic? This problem happens also with VB. But later :), By example if you use decimal type, smallest non-zero number is +/-0.0001, that differs from php. But just for your information, make my past remarks a general rule on howto work with floating point number, any langage, any platform. Just a fact. hth pa -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] why won't session_start() work?
Ryan, you need to make all of those calls *before* ANY output has been sent by your script, otherwise you can't send a header any more. so the TOP of a script might look like ?php session_start(); $signor = $monsieur + $madame; session_register(signor); // the rest of your code goes here ? html ?php // more PHP ? if you get what I mean. you can actually do a lot of coding before you start the session if you want, provided you haven't done any echo() print() or anything that sends information as output. HTH beau // -Original Message- // From: Ryan Snow [mailto:[EMAIL PROTECTED]] // Sent: Thursday, 28 February 2002 9:06 AM // To: [EMAIL PROTECTED] // Subject: [PHP-DB] why won't session_start() work? // // // // when I do: // session_start(); // session_register('signor'); // session_register('username'); // // // I get: // // Warning: Cannot send session cookie - headers already sent // by (output // started at /var/www/html/index.php:3) in // /var/www/html/index.php on line 14 // // Warning: Cannot send session cache limiter - headers already // sent (output // started at /var/www/html/index.php:3) in // /var/www/html/index.php on line 14 // // Anybody know why? // // Thanks. // // Ry // // -- // PHP Database Mailing List (http://www.php.net/) // To unsubscribe, visit: http://www.php.net/unsub.php // -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] Why NULL?
Yes, I did not receive any replies to that message yesterday. Here is my code (condensed) as well. What ends up happening is that when I write a variable for a field that did have data, for example cus034a, to the db it shows a value of 0 when I intended it to be NULL. Thanks. Zach # partial table definition username CHAR(6) NOT NULL, password CHAR(8) NOT NULL, int_id VARCHAR(4) NOT NULL, cus034a TINYINT UNSIGNED NULL, cus034b TINYINT UNSIGNED NULL, cus034c TINYINT UNSIGNED NULL, sat01 TINYINT UNSIGNED NULL, PRIMARY KEY(password, int_id) // php script // INITIALIZE DATA ARRAY function initialize_data() { // create array to store record $data_array = array(); $data_array[username] = ; $data_array[password] = ; $data_array[int_id] = ; $data_array[cus034a] = NULL; $data_array[cus034b] = NULL; $data_array[cus034c] = NULL; $data_array[sat01] = NULL; ... ... ... return $data_array; } // CREATE ARRAY TO HOLD FLAT FILE $file_array = array(); $file_array = file(DAT_FILE); $count = count($file_array); if ($count == 0) echo pNo records found in dat.cgi file./p; // initialize data array $data_array = initialize_data(); // $i is the current element in the $file_array // LOOP THRU FLAT FILE while ($i $count) { // extract header data $data_array[username] = trim(substr($file_array[$i], 0, 12)); $data_array[password] = trim(substr($file_array[$i], 12, 8)); $data_array[int_id] = trim(substr($file_array[$i], 20, 4)); // extract response data for ($j = 0; $j $data_array[num_responses]; $j++) { $i++; $extract_array = explode(,, $file_array[$i]); if ($extract_array[0] == cus034a) { $data_array[cus034a] = $extract_array[1]; } elseif ($extract_array[0] == cus034b) { $data_array[cus034b] = $extract_array[1]; } elseif ($extract_array[0] == cus034c) { $data_array[cus034c] = $extract_array[1]; } elseif ($extract_array[0] == sat01) { $data_array[sat01] = $extract_array[1]; } ... ... ... else { echo pCould not process response data for int_id: span style=\color: #80;\$int_id/span . and password: span style=\color: #80;\$password/span recorded./p; } } // end for // WRITE RECORD TO DB TABLE $date_time = date(Y-m-d H:i:s); $result2 = mysql_query(INSERT INTO s999dat SET username= '. $data_array[username] .' , password= '. $data_array[password] .' , int_id= '. $data_array[int_id] .' , cus034a= '. $data_array[cus034a] .' , cus034b= '. $data_array[cus034b] .' , cus034c= '. $data_array[cus034c] .' , sat01= '. $data_array[sat01] .' , ... ... ... ); if (mysql_affected_rows() == 0) { echo pError adding record to db.br . int_id: span style=\color: #80;\$int_id/span . and password: span style=\color: #80;\$password/spanbr . mysql_error() . /p; exit; } $i++; // INITIALIZE DATA ARRAY $data_array = initialize_data(); } // end while -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why the following error, yet it works anyway
Chip, You're not going to like this .. on the delete you aren't fetching any rows. Miles At 09:18 AM 1/14/2002 -0800, [EMAIL PROTECTED] wrote: I have the following short web page to delete dealer bulletins from a database. My page lists all the bulletins in the database - id and subject. There is a text input field to enter the bulletin id number and hit the delete button, and the bulletin is deleted. It works except after the submit delete I get an error - - Warning: Supplied argument is not a valid MySQL result resource in /usr/local/apache/htdocs/bulletin_delete.php on line 35 - line 35 is the while statement. Here is the complete page - - Simrad Dealer Bulletins - Delete Screen NOTE: This is a permanent and irreversible delete! No second chances here! Enter the bulleting ID Number: ? $db = mysql_connect(localhost, root) or die (Can't get the database server); mysql_select_db(bulletins, $db) or die (Can't get the database); if (isset($submit)): $sql = delete from dbulletins where news_id = '$newsid'; else: $sql = select news_id, bulletin_subject from dbulletins; endif; $result = mysql_query($sql); while ($row = mysql_fetch_array($result)) { print \nDelete entry .$row[news_id].? .$row[bulletin_subject].\n \n; } ? bulletin_admin.htmBack -- Chip Wiegand Computer Services Simrad, Inc www.simrad.com [EMAIL PROTECTED] There is no reason anyone would want a computer in their home. --Ken Olson, president, chairman and founder of Digital Equipment Corporation, 1977 (They why do I have 7? Somebody help me!) -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why the following error, yet it works anyway
First, if $submit is not set, then the delete statement will be executed. This will not return an array upon which mysql_fetch_array() will act. Therefore $result will not be valid. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Monday, January 14, 2002 11:18 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Why the following error, yet it works anyway I have the following short web page to delete dealer bulletins from a database. My page lists all the bulletins in the database - id and subject. There is a text input field to enter the bulletin id number and hit the delete button, and the bulletin is deleted. It works except after the submit delete I get an error - - Warning: Supplied argument is not a valid MySQL result resource in /usr/local/apache/htdocs/bulletin_delete.php on line 35 - line 35 is the while statement. Here is the complete page - - html head meta name=generator content=HTML Tidy, see www.w3.org / titleDealer Bulletins, Simrad, Inc/title /head body centerh2Simrad Dealer Bulletins - Delete Screen/h2 br /strongfont color=redNOTE: This is a permanent and irreversible delete! No second chances here!/font/strong/center hr width=75% noshade=noshade / form action=bulletin_delete.php method =POST Enter the bulleting ID Number: input type=text name=newsid input type=submit name=submit value=Delete/form table summary= border=0 cellpadding=5 align=center width=90% ? $db = mysql_connect(localhost, root) or die (Can't get the database server); mysql_select_db(bulletins, $db) or die (Can't get the database); if (isset($submit)): $sql = delete from dbulletins where news_id = '$newsid'; else: $sql = select news_id, bulletin_subject from dbulletins; endif; $result = mysql_query($sql); while ($row = mysql_fetch_array($result)) { print tr\ntdDelete entry strong.$row[news_id]./strong?nbsp; .$row[bulletin_subject]./td\n/tr\n; } ? /table center a href=bulletin_admin.phpBack/a/center /body /html -- Chip Wiegand Computer Services Simrad, Inc www.simrad.com [EMAIL PROTECTED] There is no reason anyone would want a computer in their home. --Ken Olson, president, chairman and founder of Digital Equipment Corporation, 1977 (They why do I have 7? Somebody help me!) -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why the following error, yet it works anyway
Rick Emery [EMAIL PROTECTED] wrote on 01/14/2002 10:35:37 AM: First, if $submit is not set, then the delete statement will be executed. This will not return an array upon which mysql_fetch_array() will act. Therefore $result will not be valid. I made this change: if (!isset($submit)): $sql = select news_id, bulletin_subject from dbulletins; elseif (isset($submit)): $sql = delete from dbulletins where news_id = '$newsid'; endif; but still get the same error. Shouldn't this fix the problem so now it will return the database list because the submit button is not pushed (on returning to the page)? -- Chip -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Monday, January 14, 2002 11:18 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Why the following error, yet it works anyway I have the following short web page to delete dealer bulletins from a database. My page lists all the bulletins in the database - id and subject. There is a text input field to enter the bulletin id number and hit the delete button, and the bulletin is deleted. It works except after the submit delete I get an error - - Warning: Supplied argument is not a valid MySQL result resource in /usr/local/apache/htdocs/bulletin_delete.php on line 35 - line 35 is the while statement. Here is the complete page - - html head meta name=generator content=HTML Tidy, see www.w3.org / titleDealer Bulletins, Simrad, Inc/title /head body centerh2Simrad Dealer Bulletins - Delete Screen/h2 br /strongfont color=redNOTE: This is a permanent and irreversible delete! No second chances here!/font/strong/center hr width=75% noshade=noshade / form action=bulletin_delete.php method =POST Enter the bulleting ID Number: input type=text name=newsid input type=submit name=submit value=Delete/form table summary= border=0 cellpadding=5 align=center width=90% ? $db = mysql_connect(localhost, root) or die (Can't get the database server); mysql_select_db(bulletins, $db) or die (Can't get the database); if (isset($submit)): $sql = delete from dbulletins where news_id = '$newsid'; else: $sql = select news_id, bulletin_subject from dbulletins; endif; $result = mysql_query($sql); while ($row = mysql_fetch_array($result)) { print tr\ntdDelete entry strong.$row[news_id]./strong?nbsp; .$row[bulletin_subject]./td\n/tr\n; } ? /table center a href=bulletin_admin.phpBack/a/center /body /html -- Chip Wiegand Computer Services Simrad, Inc www.simrad.com [EMAIL PROTECTED] There is no reason anyone would want a computer in their home. --Ken Olson, president, chairman and founder of Digital Equipment Corporation, 1977 (They why do I have 7? Somebody help me!) -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why use MySQL with PHP
Hmm it's not PHP functionality that makes html ugly as shown at validator.w3.org. It's the person's html/php coding ability to avoid coding mistakes. Basically, PHP gives functionality. A part of that functionality is for the php programmer to make correct HTML as output so the browser will render a page as output correctly. If the php programmer is a real bonehead and he/she can't instruct php to return good HTML that doesn't make a HTML validator from coughing up errors, it's not PHP's fault, it's the coders. I've been programming PHP for quite a while now and I can't think of a single regular thing in PHP that'd cause any browser (Netscape or IE) to hang. Any time that I've had problems, it's because I didn't know the limits of what I was coding to try and do something that is outside the possibilities. Whether it's storing information in a database, retrieving information from a database, sending PHP headers to redirect to another page or sending PHP headers to set a cookie, etc. You have to know when you can do things in PHP and when you can't. If web pages hang in a browser, it's the buggy PHP code that is interpreted that's causing the problems. Not PHP itself. It's like putting gasoline w/ water in a gas tank. It's not the engine's fault it's spitting and sputtering. It's the fuel supply. Tyler Nally [EMAIL PROTECTED] American Legion Website -Original Message- From: Sheridan Saint-Michel [mailto:[EMAIL PROTECTED]] Sent: Thursday, November 15, 2001 6:02 PM To: B. van Ouwerkerk; [EMAIL PROTECTED] Subject: Re: [PHP-DB] Why use MySQL with PHP Tell me about it. You ever try running php.net through http://validator.w3.org ? It's not pretty. Sheridan Saint-Michel Website Administrator FoxJet, an ITW Company www.foxjet.com - Original Message - From: B. van Ouwerkerk [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, November 15, 2001 12:28 PM Subject: Re: [PHP-DB] Why use MySQL with PHP I just remembered, the only bad thing I can think of about MySQL... their website locks up Netscape =) PHP qualifies for this too. www.php.net looks pretty messy in NS. By the way, both doesn't break NS.. Bye, B. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why use MySQL with PHP
Oh PHP itself isn't to blame at all, and I never intended to infer that. If you point the W3C validator at www.foxjet.com you will get a clean rating and that page is generated via PHP. Someone mentioned that they got errors in Netscape and I was just pointing out that for some reason the people who built www.php.net didn't make the page W3C compliant. Sheridan Saint-Michel Website Administrator FoxJet, an ITW Company www.foxjet.com - Original Message - From: Nally, Tyler G. [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, November 16, 2001 8:36 AM Subject: RE: [PHP-DB] Why use MySQL with PHP Hmm it's not PHP functionality that makes html ugly as shown at validator.w3.org. It's the person's html/php coding ability to avoid coding mistakes. Basically, PHP gives functionality. A part of that functionality is for the php programmer to make correct HTML as output so the browser will render a page as output correctly. If the php programmer is a real bonehead and he/she can't instruct php to return good HTML that doesn't make a HTML validator from coughing up errors, it's not PHP's fault, it's the coders. I've been programming PHP for quite a while now and I can't think of a single regular thing in PHP that'd cause any browser (Netscape or IE) to hang. Any time that I've had problems, it's because I didn't know the limits of what I was coding to try and do something that is outside the possibilities. Whether it's storing information in a database, retrieving information from a database, sending PHP headers to redirect to another page or sending PHP headers to set a cookie, etc. You have to know when you can do things in PHP and when you can't. If web pages hang in a browser, it's the buggy PHP code that is interpreted that's causing the problems. Not PHP itself. It's like putting gasoline w/ water in a gas tank. It's not the engine's fault it's spitting and sputtering. It's the fuel supply. Tyler Nally [EMAIL PROTECTED] American Legion Website -Original Message- From: Sheridan Saint-Michel [mailto:[EMAIL PROTECTED]] Sent: Thursday, November 15, 2001 6:02 PM To: B. van Ouwerkerk; [EMAIL PROTECTED] Subject: Re: [PHP-DB] Why use MySQL with PHP Tell me about it. You ever try running php.net through http://validator.w3.org ? It's not pretty. Sheridan Saint-Michel Website Administrator FoxJet, an ITW Company www.foxjet.com - Original Message - From: B. van Ouwerkerk [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, November 15, 2001 12:28 PM Subject: Re: [PHP-DB] Why use MySQL with PHP I just remembered, the only bad thing I can think of about MySQL... their website locks up Netscape =) PHP qualifies for this too. www.php.net looks pretty messy in NS. By the way, both doesn't break NS.. Bye, B. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why use MySQL with PHP
Personally I prefer Sybase on Linux, version 11_0_3 is free for production use and easy to install. Sybase 11_0_3 is still a very powerful DBMS although a bit dated by now, Sybase just released version 12.5. Why everyone is using MySQL I don't know, could it be that mod_php is compiled with MySQL support? MySQL is free and there is a lot of support from the community since so many are using it. How would one go about making a mod_php with Sybase support also? Regards //Richard -Original Message- From: søren eriksen [mailto:[EMAIL PROTECTED]] Sent: Thursday, November 15, 2001 9:34 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why use MySQL with PHP
My reasons: 1) Heard of Oracle, didnt know it was a database program 2) Never heard of PostgreSQL 3) MySQL is the most talked about, from what I've seen, so there's plenty of people to get help from 4) It's free. 5) It runs in Windows 5) NASA uses it, or so their site says 6) It works! So I've no need to switch to anything else 7) Most PHP webhosting services offer only MySQL. 8) Gotta love that lil dolphin! søren eriksen wrote: Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- From PHPGalaxy.com, earn up to $10 per order selling our PHP Scripts and Software on your Site. http://www.phpgalaxy.com/aff/ Also, get a fast free POP3 email account, you @php.la at http://www.phpgalaxy.com/search/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why use MySQL with PHP
The main reasons are possibly later on its drawbacks - basically, its main attraction is the ease of use, as it's so simple! MySQL and PHP fit together so well and for people just learning scripting with databases, there's not much that's as easy to pick up quickly and produce basic database driven websites with. Obviously due to this, it's actually got no massive depth in terms of stored procedures (you can't), and won't be as effective or useful for running massive, complex sites that attract millions of visitors (something like SQL server would probably be better) but for most websites, it's free, it's easy, and it does the job! -Original Message- From: søren eriksen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 20:34 To: [EMAIL PROTECTED] Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why use MySQL with PHP
*laugh* I was reading this and thought to reply simply for the fact Søren is fellow danish guy, but refrained momentarily till I got this one... There are many alternatives to mySQL and much more commercial too... Try get your hotshot boss to belive in mySQL rather from business buzzword Oracle (by know, I think 95% know Oracle is the major db engine - especially on the ridiculus pricetag it comes with), but MSSQL, Sybase, PostgreSQL, Informix, Paradox ect ect ect. Okay, I am a bit colored by my short but exiting experience over 4 years pro. Since the zend guys came into the picture with the rewriting of php engine they worked quite close with monty and the boyz over at mySQL... The integration between these two systems is one of the closest and seemlessly I have seen to date, with experience from IPerForm/MSSQL6.5(later 7.0) - if you dont know IPerForm, be happy about it and never think of it - JSP/Servlet/Oracle and latest PHP/mySQL. It is unique, fast and never a problem needless what platform it runs on (though I advice noone to do Windowshosting with PHP/mySQL *ouch* can already feel I'm being dragged outside and beaten upon - Windows if for testing and development only, I always run on FreeBSD or Linux servers and it ruuuns smth) Hmm, about the Nasa part, I never conducted business quite like the guys at Nasa so I presume my needs is quite different - prefer to find the optimal solution... Heck, there are alot of bigshot sites out there running ASP *www* does that mean it is the optimal solution ? Wasn't it Ratschiller / Gerken (sorry if I got the names wrong) who had an entire chapter about the PHP / mySQL tieup - well, check their book out, I dont agree with it in full but it has its great parts... :) Enough storytelling, goodluck on your assignment / Lars PS. Søren, skriv hvis der er noget... Jeg har arbejdet de sidste par år med PHP / mySQL for firmaer som TDC KabelTV og lign. -Original Message- From: PHPGalaxy.com [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 20:38 To: søren eriksen Cc: [EMAIL PROTECTED] Subject: Re: [PHP-DB] Why use MySQL with PHP My reasons: 1) Heard of Oracle, didnt know it was a database program 2) Never heard of PostgreSQL 3) MySQL is the most talked about, from what I've seen, so there's plenty of people to get help from 4) It's free. 5) It runs in Windows 5) NASA uses it, or so their site says 6) It works! So I've no need to switch to anything else 7) Most PHP webhosting services offer only MySQL. 8) Gotta love that lil dolphin! søren eriksen wrote: Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- From PHPGalaxy.com, earn up to $10 per order selling our PHP Scripts and Software on your Site. http://www.phpgalaxy.com/aff/ Also, get a fast free POP3 email account, you @php.la at http://www.phpgalaxy.com/search/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why use MySQL with PHP
Sure, the big guys run ASP, but its common knowledge to stay aay from that =) Actually, the reaosn I brought it up is cuz I'm sure they have some pretty big databases, for whatever they use it for, and wellanything that's gonna support a huge DB without crashing is a plus in my book =)I tried to host some php sites on my Win2k computer, and it worked out well..until people actually started visiting the site =) Thus, great for testing, bad for hosting. =) I do use it though to build databases. I have a number of different types of search engine spiders that index sites, and I find it easier to do it here than on my php web host. =) I just realized, I could talk about PHP and MySQL all day...or until my fingers fall off... so I'll end this here =) Lars B. Jensen wrote: *laugh* I was reading this and thought to reply simply for the fact Søren is fellow danish guy, but refrained momentarily till I got this one... There are many alternatives to mySQL and much more commercial too... Try get your hotshot boss to belive in mySQL rather from business buzzword Oracle (by know, I think 95% know Oracle is the major db engine - especially on the ridiculus pricetag it comes with), but MSSQL, Sybase, PostgreSQL, Informix, Paradox ect ect ect. Okay, I am a bit colored by my short but exiting experience over 4 years pro. Since the zend guys came into the picture with the rewriting of php engine they worked quite close with monty and the boyz over at mySQL... The integration between these two systems is one of the closest and seemlessly I have seen to date, with experience from IPerForm/MSSQL6.5(later 7.0) - if you dont know IPerForm, be happy about it and never think of it - JSP/Servlet/Oracle and latest PHP/mySQL. It is unique, fast and never a problem needless what platform it runs on (though I advice noone to do Windowshosting with PHP/mySQL *ouch* can already feel I'm being dragged outside and beaten upon - Windows if for testing and development only, I always run on FreeBSD or Linux servers and it ruuuns smth) Hmm, about the Nasa part, I never conducted business quite like the guys at Nasa so I presume my needs is quite different - prefer to find the optimal solution... Heck, there are alot of bigshot sites out there running ASP *www* does that mean it is the optimal solution ? Wasn't it Ratschiller / Gerken (sorry if I got the names wrong) who had an entire chapter about the PHP / mySQL tieup - well, check their book out, I dont agree with it in full but it has its great parts... :) Enough storytelling, goodluck on your assignment / Lars PS. Søren, skriv hvis der er noget... Jeg har arbejdet de sidste par år med PHP / mySQL for firmaer som TDC KabelTV og lign. -Original Message- From: PHPGalaxy.com [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 20:38 To: søren eriksen Cc: [EMAIL PROTECTED] Subject: Re: [PHP-DB] Why use MySQL with PHP My reasons: 1) Heard of Oracle, didnt know it was a database program 2) Never heard of PostgreSQL 3) MySQL is the most talked about, from what I've seen, so there's plenty of people to get help from 4) It's free. 5) It runs in Windows 5) NASA uses it, or so their site says 6) It works! So I've no need to switch to anything else 7) Most PHP webhosting services offer only MySQL. 8) Gotta love that lil dolphin! søren eriksen wrote: Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- From PHPGalaxy.com, earn up to $10 per order selling our PHP Scripts and Software on your Site. http://www.phpgalaxy.com/aff/ Also, get a fast free POP3 email account, you @php.la at http://www.phpgalaxy.com/search/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- From PHPGalaxy.com, earn up to $10 per order selling our PHP Scripts and Software on your Site. http://www.phpgalaxy.com/aff/ Also, get a fast free POP3 email account, you @php.la at http://www.phpgalaxy.com/search/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list
RE: [PHP-DB] Why use MySQL with PHP
Stored procedures is missing in mySQL correct but is scheduled with the exiting launch of the mySQL 4 family. mySQL has it's drawbacks, but main force is it's performance, for certain tasks also with quite large datasets (few million rows) I had mySQL outperform major players as Microsoft SQL Server 7 and Oracle8i. I sadly never had my hands on PostgreSQL yet. Again, it all comes down to make the optimal site for the job, not the hardest technological. To revert a saying, why jump the fence where it is the highest ? (thereby not saying we gotta jump where it is lowest, but where it is appropriate to the task). So, with experience and knowledge from major sites running daily thousands of sessions and millions of pageviews I know mySQL is capable of the trick, and with the mySQL 4 coming out, I for one is awaiting it with anticipation. Especially the stored procedures which totally would eliminate my need for Microsoft SQL Server. / Lars -Original Message- From: matt stewart [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 20:45 To: 'søren eriksen'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP The main reasons are possibly later on its drawbacks - basically, its main attraction is the ease of use, as it's so simple! MySQL and PHP fit together so well and for people just learning scripting with databases, there's not much that's as easy to pick up quickly and produce basic database driven websites with. Obviously due to this, it's actually got no massive depth in terms of stored procedures (you can't), and won't be as effective or useful for running massive, complex sites that attract millions of visitors (something like SQL server would probably be better) but for most websites, it's free, it's easy, and it does the job! -Original Message- From: søren eriksen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 20:34 To: [EMAIL PROTECTED] Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why use MySQL with PHP
sounds wonderful - do you know when (roughly) it's gonna be released? I thought that one of the reasons it was so fast was that the DB engine wasn't cluttered with procedures? (which is why it's so damn good for not-so-complicated sites)? i'm no expert at all, but won't mySQL 4 therefore be slower? -Original Message- From: Lars B. Jensen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 12:19 To: matt stewart Cc: [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP Stored procedures is missing in mySQL correct but is scheduled with the exiting launch of the mySQL 4 family. mySQL has it's drawbacks, but main force is it's performance, for certain tasks also with quite large datasets (few million rows) I had mySQL outperform major players as Microsoft SQL Server 7 and Oracle8i. I sadly never had my hands on PostgreSQL yet. Again, it all comes down to make the optimal site for the job, not the hardest technological. To revert a saying, why jump the fence where it is the highest ? (thereby not saying we gotta jump where it is lowest, but where it is appropriate to the task). So, with experience and knowledge from major sites running daily thousands of sessions and millions of pageviews I know mySQL is capable of the trick, and with the mySQL 4 coming out, I for one is awaiting it with anticipation. Especially the stored procedures which totally would eliminate my need for Microsoft SQL Server. / Lars -Original Message- From: matt stewart [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 20:45 To: 'søren eriksen'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP The main reasons are possibly later on its drawbacks - basically, its main attraction is the ease of use, as it's so simple! MySQL and PHP fit together so well and for people just learning scripting with databases, there's not much that's as easy to pick up quickly and produce basic database driven websites with. Obviously due to this, it's actually got no massive depth in terms of stored procedures (you can't), and won't be as effective or useful for running massive, complex sites that attract millions of visitors (something like SQL server would probably be better) but for most websites, it's free, it's easy, and it does the job! -Original Message- From: søren eriksen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 20:34 To: [EMAIL PROTECTED] Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP-DB] Why use MySQL with PHP
Well, need to hook up on mysql.com to check it out... 4.0 is already out on development, but even I tend to tell my clients I am on the cutting-edge *laugh* yeah, I know - bullshit buzzword - I prefer it to be stable releases before relying even remotely on these. mySQL 4.1 will become VERY exciting with the fulltext indexing (more than a mere OR search), Stored Procedures and even they promise an performance increase... hmm, our buddies at mySQL seem to make alot of promises, lets just hope they are not like politicians and actually will put a product behind the words to back it up. Monty and co. got my confidence, I look forward playing with a new toy. Refs : http://www.mysql.com/products/mysql-4.0/index.html And : http://www.mysql.com/news/article-81.html / Lars -Original Message- From: matt stewart [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 21:32 To: 'Lars B. Jensen'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP sounds wonderful - do you know when (roughly) it's gonna be released? I thought that one of the reasons it was so fast was that the DB engine wasn't cluttered with procedures? (which is why it's so damn good for not-so-complicated sites)? i'm no expert at all, but won't mySQL 4 therefore be slower? -Original Message- From: Lars B. Jensen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 12:19 To: matt stewart Cc: [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP Stored procedures is missing in mySQL correct but is scheduled with the exiting launch of the mySQL 4 family. mySQL has it's drawbacks, but main force is it's performance, for certain tasks also with quite large datasets (few million rows) I had mySQL outperform major players as Microsoft SQL Server 7 and Oracle8i. I sadly never had my hands on PostgreSQL yet. Again, it all comes down to make the optimal site for the job, not the hardest technological. To revert a saying, why jump the fence where it is the highest ? (thereby not saying we gotta jump where it is lowest, but where it is appropriate to the task). So, with experience and knowledge from major sites running daily thousands of sessions and millions of pageviews I know mySQL is capable of the trick, and with the mySQL 4 coming out, I for one is awaiting it with anticipation. Especially the stored procedures which totally would eliminate my need for Microsoft SQL Server. / Lars -Original Message- From: matt stewart [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 20:45 To: 'søren eriksen'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP The main reasons are possibly later on its drawbacks - basically, its main attraction is the ease of use, as it's so simple! MySQL and PHP fit together so well and for people just learning scripting with databases, there's not much that's as easy to pick up quickly and produce basic database driven websites with. Obviously due to this, it's actually got no massive depth in terms of stored procedures (you can't), and won't be as effective or useful for running massive, complex sites that attract millions of visitors (something like SQL server would probably be better) but for most websites, it's free, it's easy, and it does the job! -Original Message- From: søren eriksen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 20:34 To: [EMAIL PROTECTED] Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail
Re: [PHP-DB] Why use MySQL with PHP
I just remembered, the only bad thing I can think of about MySQL... their website locks up Netscape =) I recently installed MySQL4 dev on one of the Win2k computers and it seems to work well...I havent stress-tested it much, or do anything complex with it (I'm still a beginner anyways), but I invite anyone else to try =) 65.7.204.217 - root/no password - the computer nor MySQL gets used for anything else, so go nuts with it! I'm kinda curious anyways to see what people do to/with it. oh yeah, phpmyadmin is on there at http://65.7.204.217:81/sql/ =) Lars B. Jensen wrote: Well, need to hook up on mysql.com to check it out... 4.0 is already out on development, but even I tend to tell my clients I am on the cutting-edge *laugh* yeah, I know - bullshit buzzword - I prefer it to be stable releases before relying even remotely on these. mySQL 4.1 will become VERY exciting with the fulltext indexing (more than a mere OR search), Stored Procedures and even they promise an performance increase... hmm, our buddies at mySQL seem to make alot of promises, lets just hope they are not like politicians and actually will put a product behind the words to back it up. Monty and co. got my confidence, I look forward playing with a new toy. Refs : http://www.mysql.com/products/mysql-4.0/index.html And : http://www.mysql.com/news/article-81.html / Lars -Original Message- From: matt stewart [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 21:32 To: 'Lars B. Jensen'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP sounds wonderful - do you know when (roughly) it's gonna be released? I thought that one of the reasons it was so fast was that the DB engine wasn't cluttered with procedures? (which is why it's so damn good for not-so-complicated sites)? i'm no expert at all, but won't mySQL 4 therefore be slower? -Original Message- From: Lars B. Jensen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 12:19 To: matt stewart Cc: [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP Stored procedures is missing in mySQL correct but is scheduled with the exiting launch of the mySQL 4 family. mySQL has it's drawbacks, but main force is it's performance, for certain tasks also with quite large datasets (few million rows) I had mySQL outperform major players as Microsoft SQL Server 7 and Oracle8i. I sadly never had my hands on PostgreSQL yet. Again, it all comes down to make the optimal site for the job, not the hardest technological. To revert a saying, why jump the fence where it is the highest ? (thereby not saying we gotta jump where it is lowest, but where it is appropriate to the task). So, with experience and knowledge from major sites running daily thousands of sessions and millions of pageviews I know mySQL is capable of the trick, and with the mySQL 4 coming out, I for one is awaiting it with anticipation. Especially the stored procedures which totally would eliminate my need for Microsoft SQL Server. / Lars -Original Message- From: matt stewart [mailto:[EMAIL PROTECTED]] Sent: 15. november 2001 20:45 To: 'søren eriksen'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Why use MySQL with PHP The main reasons are possibly later on its drawbacks - basically, its main attraction is the ease of use, as it's so simple! MySQL and PHP fit together so well and for people just learning scripting with databases, there's not much that's as easy to pick up quickly and produce basic database driven websites with. Obviously due to this, it's actually got no massive depth in terms of stored procedures (you can't), and won't be as effective or useful for running massive, complex sites that attract millions of visitors (something like SQL server would probably be better) but for most websites, it's free, it's easy, and it does the job! -Original Message- From: søren eriksen [mailto:[EMAIL PROTECTED]] Sent: 15 November 2001 20:34 To: [EMAIL PROTECTED] Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295 / Virus Database: 159 - Release Date: 01/11/01 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.295
Re: [PHP-DB] Why use MySQL with PHP
I just remembered, the only bad thing I can think of about MySQL... their website locks up Netscape =) PHP qualifies for this too. www.php.net looks pretty messy in NS. By the way, both doesn't break NS.. Bye, B. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why use MySQL with PHP
I use PHP/MySQL for a few reasons. 1) Ease of Use - I am a Computer Science student and a Web Programmer. As such have been exposed to a wide variety of programming languages and environments. PHP/MySQL is one of the easiest to work with and learn, and is THE easiest to do Web related things with (and yes, I have used and am including ASP in that statement). 2) Availability - By this I mean not only that both PHP and MySQL are free (which is a big factor for us starving student types), but that they setup very easily on a variety of platforms. This means I can test scripts on a copy of the MySQL DB from my Linux Server on my windows box before uploading them. 3) Support - Both PHP and MySQL have very good Manuals which are very easily accessable (both online and downloadable). In addition, I have received extremely valuable help from the PHP mailling lists on both PHP and MySQL questions. In most cases I have gotten faster and better responses than I get from professors at school (who I am asking things concerning their class...not PHP =P ) who I am paying to teach me. That alone is quite a strong arguement. 4) Good Balance between Flexibility and Readability - In PERL they have a saying There's More Than One Way To Do It. I think this is a good philosophy, but PERL takes this to more of an extreme than I like (this is not to say that this extreme is not right for some people). When I read through a 50 line program in a language that I am fairly skilled at I shouldn't have to refer to the manual more than say a dozen times...right? In Perl I often find myself having to refer to manuals a dozen times for two or three lines! For example: perl -we '$_ = q ?4a75737420616e6f74686572205065726c204861636b65720as?;??; for (??;(??)x??;??) {??;s;(..)s?;qq ?print chr 0x$1 and \161 ss?;excess;??}' Any idea what that one does? Without running it? Paste it into a terminal... it should run as is (does on my Linux box with PERL 5 anyway). On the other hand, having to write in languages where you have strict types (You want to treat a variable as an int and then as a string?!?!?!?) and very structured design is just as distasteful to me. PHP strikes a very good balance between the two even when working with MySQL (I won't paste any of the kludge needed to interface with CGI and DB in other languages... but if you have some free time look some of these programs up). Sheridan Saint-Michel Website Administrator FoxJet, an ITW Company www.foxjet.com - Original Message - From: søren eriksen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, November 15, 2001 2:34 PM Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why use MySQL with PHP
I wrote this a few month ago for the db comparaison. It's simple and you can easily add to it: http://zc8.com/zc8/ZC8news/shownews.php?articleid=571 As for PHP my reasons are: * No need to typecast which makes it easier to code. * You can have multi-dimensional multi-cast arrays which in many case can do instead of objects. * It's nothing to learn if you already know a modular language (pascal, c, java...). * It types easily within your html code and it is extremelly readable (although you can put some effort into making it hard to read). * No need to compile. * It's open source * You can compile it with Apache and with your specs. * Many interesting module available (like Ming) * It's very portable. * It's widely present on web server. * It has easy communications with databases, ftp, remote ip files, mail... * It has great support and online reference. * It is very well maintained. * Lot's of sample code on the web to look at. And I probably forget a lot On Thursday 15 November 2001 12:53 pm, Sheridan Saint-Michel wrote: I use PHP/MySQL for a few reasons. 1) Ease of Use - I am a Computer Science student and a Web Programmer. As such have been exposed to a wide variety of programming languages and environments. PHP/MySQL is one of the easiest to work with and learn, and is THE easiest to do Web related things with (and yes, I have used and am including ASP in that statement). 2) Availability - By this I mean not only that both PHP and MySQL are free (which is a big factor for us starving student types), but that they setup very easily on a variety of platforms. This means I can test scripts on a copy of the MySQL DB from my Linux Server on my windows box before uploading them. 3) Support - Both PHP and MySQL have very good Manuals which are very easily accessable (both online and downloadable). In addition, I have received extremely valuable help from the PHP mailling lists on both PHP and MySQL questions. In most cases I have gotten faster and better responses than I get from professors at school (who I am asking things concerning their class...not PHP =P ) who I am paying to teach me. That alone is quite a strong arguement. 4) Good Balance between Flexibility and Readability - In PERL they have a saying There's More Than One Way To Do It. I think this is a good philosophy, but PERL takes this to more of an extreme than I like (this is not to say that this extreme is not right for some people). When I read through a 50 line program in a language that I am fairly skilled at I shouldn't have to refer to the manual more than say a dozen times...right? In Perl I often find myself having to refer to manuals a dozen times for two or three lines! For example: perl -we '$_ = q ?4a75737420616e6f74686572205065726c204861636b65720as?;??; for (??;(??)x??;??) {??;s;(..)s?;qq ?print chr 0x$1 and \161 ss?;excess;??}' Any idea what that one does? Without running it? Paste it into a terminal... it should run as is (does on my Linux box with PERL 5 anyway). On the other hand, having to write in languages where you have strict types (You want to treat a variable as an int and then as a string?!?!?!?) and very structured design is just as distasteful to me. PHP strikes a very good balance between the two even when working with MySQL (I won't paste any of the kludge needed to interface with CGI and DB in other languages... but if you have some free time look some of these programs up). Sheridan Saint-Michel Website Administrator FoxJet, an ITW Company www.foxjet.com - Original Message - From: søren eriksen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, November 15, 2001 2:34 PM Subject: [PHP-DB] Why use MySQL with PHP Hi everybody I'm writing a synopsis about PHP and mySQL. I'm hoping someone can help me, and tell me why the combination og PHP and MySQL is so common. What makes MySQL such a good choice when using PHP? What seperates MySQL from others dbms? -Søren Eriksen- -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why use MySQL with PHP
I mostly agree, although I prefer PostgreSQL for the transactions, better row locking, and server side cursors. It also does better with lotsa users (if the data isn't just used for the web, this is important). I have used many languages for this stuff, and the one with the best balance of functionality, extensibility, and ease of use is PHP (I have used CF, ASP, Miva/HTMLScript, PERL, C, COBOL, Shell also) BTW, COBOL on the web is weird. ASP is the worst of them all. Sheridan Saint-Michel wrote: I use PHP/MySQL for a few reasons. snip/snip On the other hand, having to write in languages where you have strict types (You want to treat a variable as an int and then as a string?!?!?!?) and very structured design is just as distasteful to me. PHP strikes a very good balance between the two even when working with MySQL (I won't paste any of the kludge needed to interface with CGI and DB in other languages... but if you have some free time look some of these programs up). Sheridan Saint-Michel Website Administrator FoxJet, an ITW Company www.foxjet.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Why use MySQL with PHP
Tell me about it. You ever try running php.net through http://validator.w3.org ? It's not pretty. Sheridan Saint-Michel Website Administrator FoxJet, an ITW Company www.foxjet.com - Original Message - From: B. van Ouwerkerk [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, November 15, 2001 12:28 PM Subject: Re: [PHP-DB] Why use MySQL with PHP I just remembered, the only bad thing I can think of about MySQL... their website locks up Netscape =) PHP qualifies for this too. www.php.net looks pretty messy in NS. By the way, both doesn't break NS.. Bye, B. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]