Re: [PHP-DB] array_diff usage

2001-04-03 Thread Martin Skjöldebrand
On Monday 02 April 2001 15:41, you wrote: -Original Message- From: Martin Skjoldebrand [mailto:[EMAIL PROTECTED]] Sent: Saturday, March 31, 2001 10:52 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] array_diff usage I'm daft. I don't understand the PHP Manual. I have two

Re: [PHP-DB] Going bonkers again ...

2001-03-23 Thread Martin Skjöldebrand
olinux wrote: You have to escape your "" $query = "SELECT m_sender, m_date, m_subject FROM messages WHERE m_id = '$m_id'"; try this $query = "SELECT m_sender, m_date, m_subject FROM messages WHERE m_id = \"$m_id\" "; No that isn't the problem. It is valid to change quotation

[PHP-DB] Line breaks in output

2001-03-19 Thread Martin Skjöldebrand
Newbie here. How do I get line breaks in output from a database? I have a list of things in a file, like: item1``item2``item3 (etc) I want them displyed in a textarea as: item1 item2 item3 Probably very simple, haven't got that far in my book yet. Martin S. -- PHP Database Mailing List

[PHP-DB] getting last entry in database table

2001-03-17 Thread Martin Skjöldebrand
I have a table containing steps toward solving a problem. I want to pass the last entry to another database as a solution. How do I do this? What I've tried today is: ? if (isset($cmdAddtoKb)) { // If I want to move the solution do ... $querykb ="SELECT e_description FROM events WHERE t_id

Re: [PHP-DB] getting last entry in database table

2001-03-17 Thread Martin Skjöldebrand
David Balatero wrote: Do this: $querykb = "SELECT e_description FROM events WHERE t_id = '$t_id' ORDER BY id desc"; where id is the unique id of each row. Then it will order it like: Entry 2 Entry 1 Yes, possibly. But it still doesn't add the last entry to the variable like I want

[PHP-DB] Error prevention

2001-03-13 Thread Martin Skjöldebrand
I'm baffled (again ) In my mql database I'm doing: SELECT cl_login FROM client WHERE cl_login = "xxx"; and if "xxx" exists I get the result xxx while if it doesn't exist I get an empty string. In PHP I'm doing $querytest = "SELECT cl_login FROM client WHERE cl_login = '$txtLogin';";

RE: [PHP-DB] Error prevention

2001-03-13 Thread Martin Skjöldebrand
Michael Rudel wrote: Hi Martin, ... you forgot to 'mysql_fetch_row' or 'mysql_result'. Read about it in the PHP-Manual in the MySQL Functions. Thanks Mike (and everyone else who pointed this out), Sometimes you're blind. When you think you pass the "complete-and-utter-newbie" phase