Re: [PHP-DB] Run php page automatically

2001-12-21 Thread Jon Farmer
> it's better to do something like > > 0,10,20,30,40,50 * * * * /usr/bin/php -q > /home/you/yourscript.php > /dev/null or even */10 * * * * /home/you/yourscript.php > /dev/null with the first line of you php script being #!/path/to/php -q -- PHP Database Mailing List (http://www.php.ne

Re: [PHP-DB] Function OCILogon().

2001-12-21 Thread B. PERRINE
Look at php manual on www.php.net, part OCI8, about env. variables for ORACLE. ORA-12545 is typical of a NET8 error. B. le jeu 20-12-2001 à 12:09, Somsak RAKTHAI a écrit : > Dear all, > I used PHP 4.1.0 and Oracle 9i running on RedHat-7.2. > I have question about Oracle function OCILogon().

[PHP-DB] Selecting last row

2001-12-21 Thread Necro
What query can I use to select the last row in a table?? Andrew -- 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] Selecting last row

2001-12-21 Thread Bogdan Stancescu
select * order by id desc limit 1; (obviously, id must be the field you yourself order the table by in your mind when you say "last row") Necro wrote: > What query can I use to select the last row in a table?? > > Andrew > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe,

Re: [PHP-DB] Selecting last row

2001-12-21 Thread Dobromir Velev
Hi, if you're using an auto_increment field or another field which increases with every record (like date entered) you can use something like select * from table_name order by auto_field_name DESC limit 0,1 Hope this helps Dobromir Velev Web Developer http://www.websitepulse.com/ -- PHP Dat

Re: [PHP-DB] Function OCILogon().

2001-12-21 Thread Somsak RAKTHAI
Dear sir, Do you have exactly URL about part OCI8 ? thank you very much. regards, Somsak. On 21 Dec 2001, B. PERRINE wrote: > Look at php manual on www.php.net, part OCI8, about env. variables for > ORACLE. > > ORA-12545 is typical of a NET8 error. > > B. > > le jeu

[PHP-DB] Urgent! Store Data In A Text File!

2001-12-21 Thread Arik Ashepa
Can someone please tell me how can I add and retrive data from a text file I know it has something to do with Spliting...??? But I dont know the code... Please Help Me... Sincerely Arik -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additiona

[PHP-DB] ODBC MS SQL Server 7

2001-12-21 Thread Javalina
Hi to all...please can you help me ...because i cant retrieve any row of the database on MS SQL Server 7 with ODBC . i did use Openlink driver on a Solaris 6 machine (Sparc) , the database are on WIN NT4.0 my code is. '; if (!($Res_hebd=odbc_prepare($connect_odbc,$Req_hebd))) { echo

[PHP-DB] Hashes

2001-12-21 Thread Robert Weeks
I'm trying to use a hash to translate a value into something human readable. I know how to do this with an if-else but that seems like a waste of typing. I have a bunch of items in the db and their values are abbreciations such as 'm_r'. I want m_r to show on the page as "Mens Rings". I was try

[PHP-DB] MSSQL connect

2001-12-21 Thread Jerry
Hi I have PHP on windows 2000 web server I would like to remote to a MS SQL database on another web server. I tried something like: But it didn't work. Please help me. Jerry -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional command

[PHP-DB] MSSQL DB Connect

2001-12-21 Thread Jerry
Hi I have PHP on windows 2000 web server I would like to remote to a MS SQL database on another web server. I tried something like: But it didn't work. Please help me. Jerry -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional command

Re: [PHP-DB] MSSQL DB Connect

2001-12-21 Thread Frank M. Kromann
Hi Jerry, You need to have the Client Tools for MS SQL Server installed on your PHP4 box. These tools is found on the CD, or you can just copy ntwdblib.dll fom one system to another. The default communication protocol will be netbios, if you want to change that to tcp/ip you need to install th

[PHP-DB] Re: MSSQL DB Connect

2001-12-21 Thread Jeremy Reed
What was the error message you received? Also, when passing the variables to the mssql_connect() function, you need not use quotes since you've already initialized them to the strings. Pass them as follows: $connection = mssql_connect($a,$b,$c). Also, you aren't passing the actual sql string t

[PHP-DB] Re: SQL/PHP problem

2001-12-21 Thread Jeremy Reed
Actually, your problem lies in your SQL code. Instead of "DELETE * FROM Table" the correct syntax is "DELETE FROM Table" Regards, Jeremy Reed "Brian Grayless" <[EMAIL PROTECTED]> wrote in message C3C8C2499A63D211BB7D00A0C9E1C7060128707F@PRI-NT1">news:C3C8C2499A63D211BB7D00A0C9E1C7060128707F@PR

RE: [PHP-DB] Hashes

2001-12-21 Thread Matthew Loff
Robert-- You're on the right track... I'm assuming $row is the result of a mysql_fetch_assoc() call, and $row['item'] contains the hashed value (either "m_r", "m_c", or whatever)... Try this: m_r, 'Mens Charm' => m_c, 'Womens Ring' => w_r,'Womens Charm' => w_c); #query db and get a result

Re: [PHP-DB] Hashes

2001-12-21 Thread Robert Weeks
Thanks, Your assumptions were correct, I'll give that a try. I ended up doing this which doesn't seem as efficient: $item_array = array('Mens Ring' => m_r, 'Mens Charm' => m_c, 'Womens Ring' => w_r, 'Womens Charm' => w_c ); while (list($val, $key) = each($item_array

Re: [PHP-DB] mysql table layout help needed

2001-12-21 Thread Chris Payne
Hi there, I format my results using the following code: "> I prefer to use this method rather than echo's as it's easier to follow (I don't know about any downsides though, I just know it's easier for me to program this way). I tried the code that you gave (Bogdan, thank you)