[PHP-DB] Using results from one mysql query to make another

2003-02-27 Thread Jason End
I have a table that includes the ids of software aplications and experts (apliexperts). My page is loaded with the variable of the software id (softid), which it uses to match the experts for that software. But instead of returning just the expert id (expid), to use that expid to get the full row

Re: [PHP-DB] help about session

2003-02-27 Thread Tatang Widyanto
Put start_session() statement on first line of your code - Original Message - From: do khac duy [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, February 27, 2003 13:31 Subject: [PHP-DB] help about session i can't start session under incule row ex: include(file.php);

Re: [PHP-DB] More help with mysql -- solved (bizarre)

2003-02-27 Thread Alexander Mejenkov
It's not bizarre behaviour $result = mysql_query(SELECT * FROM SOME_TABLE) || die (Unable to execute SQL query); returns result of logical OR operation which is TRUE or 1 without || die(...) it returns valid MySQL resource Regards Sasha Evan Morris [EMAIL PROTECTED] wrote in message

[PHP-DB] Re: More help with mysql

2003-02-27 Thread Alexander Mejenkov
Supplied argument is not a valid MySQL result resource. This is absolutely correct because after $result = mysql_query(SELECT * FROM SOME_TABLE) || die(mysql_error()); variable $result contains result of boolean OR operation which in your case is TRUE or 1 in order to get valid MySQL result you

[PHP-DB] Re: Using results from one mysql query to make another

2003-02-27 Thread Adam Royle
SELECT b.name FROM apliexperts a LEFT JOIN experts b ON a.expid = b.id WHERE softid = 2 I have a table that includes the ids of software aplications and experts (apliexperts). My page is loaded with the variable of the software id (softid), which it uses to match the experts for that software.

[PHP-DB] Re: mysql +php

2003-02-27 Thread Alejandro Trujillo J.
try to be more specific, i can help you, you have a error in your code : while ($row=mysql_fetch_row($result)) //retrieve a row and store in array $row { for($i=0; $imysql_num_fields($result);$i++) // echo (A HREF= $row[$i]); // -- echo (A HREF='{$row[$i]}'); any way this is not the way to do

[PHP-DB] Re: Parse Error

2003-02-27 Thread Alejandro Trujillo J.
if ($packages == 1) { if ($airporttransfer == car) {$airporttransfer2 = 12.00);} if ($airporttransfer == bus) {$airporttransfer2 = 10.00);} if ($airporttransfer == none){$airporttransfer2 = 0.00);} } try to learn to use the TABS and the BRACES coz is good for you and for

Re: [PHP-DB] php-dbase on RedHat 8.0

2003-02-27 Thread Jonathan Villa
That's odd. I haven't tried 4.3.1, but I do have 4.3.0 running on apache 2.0.44. I'll try 4.3.1 today and see if I come across anything. At Thursday, 27 February 2003, Roger Boily [EMAIL PROTECTED] wrote: Hi, I have upgrated to RedHat 8.0 that unfortunatly downgrade my working php 4.3.1 to

[PHP-DB] httpd keep the memory allocated even after the script ends

2003-02-27 Thread Adrian Ciocildau
Hi. I am testing some ways to insert bin amounts of data in a oracle database and i encountered the following problem. During the script execution the memory usage of httpd daemon grows a lot and even after the script is ended the httpd process keeps the memory allocated. After two runs of the

[PHP-DB] Re: MD5()

2003-02-27 Thread David Eisenhart
remember that md5() is 'not' going to help secure the data en route between the client browser and the server; consider using the encryption service SSL for this. David Chris Payne [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi there everyone, I have to store some CC details in a

RE: [PHP-DB] One more date question (NOOOOOOO) :-)

2003-02-27 Thread John W. Holmes
Sorry about all these emails :-) I have one final question (For this week - LOL). How can I get the current month + the next 11 months in a dropdown form box? Ideally there'd be 3 boxes, 1 with the day, dependant on the month you select plus the year, though I can hardcode the year without

RE: [PHP-DB] Get MySQL table schema for a dump

2003-02-27 Thread John W. Holmes
Ok, that works great. Now, what is the best way to echo the result. Just like the result from any other query. The query returns a result of one row and one column. For example $connection = mysql_connect(localhost,u,p); mysql_select_db(killerspin_com, $connection); $sql = SHOW CREATE

RE: [PHP-DB] help about session

2003-02-27 Thread John W. Holmes
i can't start session under incule row ex: include(file.php); start_session(); it say : can't add header header already sent by...v somebody can help me? You can't have any output before session_start(). Call it first in your file or fix where you have output. The error

RE: [PHP-DB] Get MySQL table schema for a dump

2003-02-27 Thread Jonathan Villa
I never thought of mysql_fetch_row. What I ended up using was $row = mysql_fetch_array($result_id); echo $row[1]; I'll probably use fetch_row as it makes more sense. Thanks. --- Jonathan -Original Message- From: John W. Holmes [mailto:[EMAIL PROTECTED] Sent: Thursday,

[PHP-DB] PHP/SSL and Hosting question

2003-02-27 Thread Chris Payne
Hi there everyone, I have a couple of questions. What is the best SSL to use on Windows - Apache 2.0 (And above) and how easy is it to configure? Which is the most stable release of PHP to use as currently I use a version from early last year (Don't remember the number off hand). I'm asking

[PHP-DB] What wrong in this SQL

2003-02-27 Thread Alawi shekh albaity
What wrong with this code in sql : $SQLSTATEMENT[DeleteCategory] = DELETE FROM cats, articles WHERE cat_id = $catid ; Error no: 1064 Details : You have an error in your SQL syntax near 'WHERE cat_id = 1 ' at line 4 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe,

RE: [PHP-DB] What wrong in this SQL

2003-02-27 Thread Ryan Jameson (USA)
I don't believe you can delete from two tables simultaneously in this fashion, it's probably the ,articles that's the error. Ryan -Original Message- From: Alawi shekh albaity [mailto:[EMAIL PROTECTED] Sent: Friday, February 28, 2003 11:04 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] What

RE: [PHP-DB] What wrong in this SQL

2003-02-27 Thread Aaron Wolski
Try escaping the $catid like: WHERE cat_id='$catid' Aaron -Original Message- From: Alawi shekh albaity [mailto:[EMAIL PROTECTED] Sent: March 1, 2003 1:04 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] What wrong in this SQL What wrong with this code in sql :

[PHP-DB] Re: PHP/SSL and Hosting question

2003-02-27 Thread Fredrik de Vibe
[EMAIL PROTECTED] (Chris Payne) writes: ... What is the best SSL to use on Windows ... [ snip ] ... any thoughts? Kind of religious, but maybe not Windows at all, at least if you're concerned about safety ;-) -- --Fredrik If God is dead, who will save the Queen? -- PHP Database Mailing

Re: [PHP-DB] What wrong in this SQL

2003-02-27 Thread Alawi shekh albaity
the problem is that mysql do not support multi table because it works when I am remove the table Thanks to all for help - Original Message - From: Adam Voigt To: Alawi shekh albaity Cc: [EMAIL PROTECTED] Sent: Thursday, February 27, 2003 11:09 AM Subject: Re: [PHP-DB] What

[PHP-DB] Update errors

2003-02-27 Thread Alawi shekh albaity
What wrong with this SQL $SQLSTATEMENT[UPDATE_CAT] = UPDATE cats SET cat_name = '$cat_name', WHERE cat_id = $catidforedit ; Error no : 1064 Details : You have an error in your SQL syntax near 'WHERE cat_id = 2 ' at line 4 Db : mysql -- PHP Database Mailing List (http://www.php.net/)

RE: [PHP-DB] Update errors

2003-02-27 Thread Hutchins, Richard
Remove the comma at the end of this line: cat_name = '$cat_name',//remove this comma -Original Message- From: Alawi shekh albaity [mailto:[EMAIL PROTECTED] Sent: Saturday, March 01, 2003 1:27 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Update errors What wrong with this SQL

RE: [PHP-DB] Update errors

2003-02-27 Thread Gary . Every
Shouldn't have a comma after cat_name = '$cat_name' unless you are updating multiple fields. Gary Every Sr. UNIX Administrator Ingram Entertainment (615) 287-4876 Pay It Forward mailto:[EMAIL PROTECTED] http://accessingram.com -Original Message- From: Alawi shekh albaity

[PHP-DB] Processing Page

2003-02-27 Thread Aspire Something
Hi all, Permit me to recive your valuable knowledge , We are working on a project where the backend churns data for about 1 Minute (time out limit is 2 min) we would like to put a page like PROCESSING during the database is busy doing its fine job. And also a sucess page appears when

RE: [PHP-DB] Processing Page

2003-02-27 Thread Gary . Every
Check out http://www.php.net/manual/en/function.ob-flush.php the ob_flush command. You could put an animated gif like an hourglass with a please wait at the beginning of your html output, perform an ob_flush command to put that info out to the browser, then perform your sql. After the sql

[PHP-DB] Re: Storing images in MySQL table

2003-02-27 Thread Pedro MG
And i've heard the server or client does not cache db stored images, while it caches them in as separate files. True ? -- Regards, Pedro MG www.tquadrado.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP-DB] Processing Page

2003-02-27 Thread Jonathan Villa
You could do this very easily using a HTML page with the correct META tags. I am working on a Domino Project right now that does just that. After a page is submitted, the user is directed to an html page which sits for about 45 seconds. This HTML page just says something like Your information

RE: [PHP-DB] Processing Page

2003-02-27 Thread Jonathan Villa
META HTTP-EQUIV=refresh CONTENT=5;url=http://yourpagehere; 5 = time to wait --- Jonathan -Original Message- From: Jonathan Villa [mailto:[EMAIL PROTECTED] Sent: Thursday, February 27, 2003 2:10 PM To: 'Aspire Something'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Processing Page

RE: [PHP-DB] Processing Page

2003-02-27 Thread Jonathan Villa
META HTTP-EQUIV=refresh CONTENT=5;url=http://yourpagehere; 5 = time to wait --- Jonathan -Original Message- From: John A DAVIS [mailto:[EMAIL PROTECTED] Sent: Thursday, February 27, 2003 2:23 PM To: [EMAIL PROTECTED] Subject: RE: [PHP-DB] Processing Page What are the correct

[PHP-DB] Re: Processing Page

2003-02-27 Thread Fredrik de Vibe
[EMAIL PROTECTED] (Aspire Something) writes: We are working on a project where the backend churns data for about 1 Minute (time out limit is 2 min) we would like to put a page like PROCESSING during the database is busy doing its fine job. And also a sucess page appears when the

RE: [PHP-DB] Re: Processing Page

2003-02-27 Thread Jonathan Villa
I guess I was thinking of a success only scenario. If the backend never failed, then an easy Meta redirect would work, (if given enough time to process). However, in the real world, assuming success is a foolish mistake. --- Jonathan -Original Message- From: [EMAIL PROTECTED]

RE: [PHP-DB] Re: Processing Page

2003-02-27 Thread Jonathan Villa
Oops, I sent my message without finishing it (that's what I get for having to many windows open). I think your #2 option would work. It's very similar to what I have done in the pass . I forgot exactly how I did it, I would have to look in my archives, but I'm pretty sure it was something like

Re: [PHP-DB] Processing Page

2003-02-27 Thread Aspire Something
Thanks every one ... All the method you told me are static it does not look if the sql statemet being exec by php along with backend has finished its job . I only wanted to show the processig page till the time the query does it's work . let me add here that the time for execution of the script

RE: [PHP-DB] Processing Page

2003-02-27 Thread Jonathan Villa
Timeout.html will redirect to verify_process.php after 30 seconds On verify_process.php you could run another query which would check the status of a certain field in the db. If this field is set to xxx, then redirect back to timeout.html, else redirect to process_complete.php. I guess this would

RE: [PHP-DB] Re: Storing images in MySQL table

2003-02-27 Thread Rich Gray
Pedro Er ... probably - I've not tested it personally. However, if you output the image directly from a database then your script is sending the http headers for content type etc and the browser has no choice but to render what you send. With HTML based img src=blah stuff it'll try to pull the

[PHP-DB] Screen size, browser on php

2003-02-27 Thread Petre NICOARA
Hi I have a small problem. I'm working on a traffic and banner xchange application, and my client asked me to retrieve as info, for each banner that is displayed or for each traffic entry the user's screen size, operating system, browser type and original language. I've found this stuff into a

[PHP-DB] selecting random rows

2003-02-27 Thread kent
I'm sure this is pretty simple, but I'm having a hard time finding the answer: How do you select two random rows in a mysql table? Thanks, Kent

Re: [PHP-DB] selecting random rows

2003-02-27 Thread Leif K-Brooks
select * from table order by rand() limit 2 [EMAIL PROTECTED] wrote: I'm sure this is pretty simple, but I'm having a hard time finding the answer: How do you select two random rows in a mysql table? Thanks, Kent -- The above message is encrypted with double rot13 encoding. Any

Re: [PHP-DB] Processing Page

2003-02-27 Thread Adam Royle
I have seen an example using JavaScript where javascript commands are flushed every so often (from PHP) which indicates a status bar process. It was used to monitor mailouts. The javascript commands were simply telling an image to increase it's width. Of course you have to have a system where

Re: [PHP-DB] Update errors

2003-02-27 Thread Jason Wong
On Saturday 01 March 2003 14:27, Alawi shekh albaity wrote: What wrong with this SQL $SQLSTATEMENT[UPDATE_CAT] = UPDATE cats SET cat_name = '$cat_name', Remove that trailing comma. WHERE cat_id = $catidforedit ; Error no : 1064 Details : You have an error in your SQL syntax

Re: [PHP-DB] Processing Page

2003-02-27 Thread olinux
I've seen a solution that looks fairly simple to implement. Basically popup a window. Popup window displays Processing please wait and an animated gif. when the page in to background is done loading it kills the popup. I think you'd use onload in the body tag. try http://javascript.faqts.com