Re: [PHP-DB] mysql tables

2002-04-24 Thread Miles Thompson
Read the MySQL docs and find out! MT At 10:27 AM 4/24/2002 +0300, Marius Ursache wrote: hi how many columns can have a mysql table? tnx -- Marius Ursache (3563 || 3494) \|/ \|/ '/ ,. \` /_| \__/ |_\

Re: [PHP-DB] MySQL to Email and Line Breaks

2002-04-14 Thread DL Neil
Jeff, I have a form where someone enters the body of an email message into a textarea part of a form to be sent out to a list. Then a script retrieves the body and sends it via email. However I can't get line breaks to show up (I'm using MS Outlook) even if I enter the \n into the textarea

Re: [PHP-DB] MySQL to Email and Line Breaks

2002-04-14 Thread Jonathan David Edwin Wright
Hiya, If I remember correctly, you much send both \r and \n to terminate a line on an e-mail, regardless of the platform. This should include the header aswell. At 12:00 14/04/2002 +0100, DL Neil wrote: Jeff, I have a form where someone enters the body of an email message into a textarea

RE: [PHP-DB] MySQL to Email and Line Breaks

2002-04-14 Thread Jeff Oien
How do I get it to do that? I tried replacing \n with \r\n but it's not even finding any \n. This is really puzzling me. If I copy the data from the database field using MySQL-Front and paste it into a word processor it will have the line breaks retained. But what is it in the data that shows

Re: [PHP-DB] MySQL to Email and Line Breaks

2002-04-14 Thread DL Neil
Jeff, Is there something about the evaluation of \n in different types of strings, eg single quotes/double quotes? (I don't know the answer)... FWIW I don't like (perhaps, I don't trust) the \r\n type of short-cuts. Herewith some sample code: ... $LinkText= Requested data can be

Re: [PHP-DB] MySQL to Email and Line Breaks

2002-04-13 Thread olinux
check out nl2br() function [newline to break] http://www.php.net/manual/en/function.nl2br.php olinux Jeff Oien wrote: I have a form where someone enters the body of an email messageinto a part of a form to be sent out to a list. Then a script retrieves the body and sends it via email.

RE: [PHP-DB] MySQL to Email and Line Breaks

2002-04-13 Thread Jeff Oien
This isn't what I'm looking for because the output is to email not HTML. What I would like is the natural line breaks in the form input to be preserved and then result in line breaks in the email without having to add any \n, which didn't work anyway. Jeff Oien check out nl2br() function

Re: [PHP-DB] MySQL/PHP Update

2002-03-28 Thread cristi radulescu
i think the problem is bad syntax: you should try: mysql_query(update prod_list set prod_manu=$prod_man where sku='.$prod.'); that is because when you have single quotes you will not evaluate the expression so your querry will do the update only for sku equally with the string '$prod'... hope

RE: [PHP-DB] MySQL/PHP Update

2002-03-28 Thread Rick Emery
Jason, this is intriguing. Please show us a bit more code before the mysql_query() call. -Original Message- From: Jason [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 28, 2002 1:54 AM To: Php-Db Subject: [PHP-DB] MySQL/PHP Update I'm trying to update my MySQL database, but it

Re: [PHP-DB] MySQL/PHP Update

2002-03-28 Thread Jason Wong
On Thursday 28 March 2002 17:04, cristi radulescu wrote: i think the problem is bad syntax: you should try: mysql_query(update prod_list set prod_manu=$prod_man where sku='.$prod.'); that is because when you have single quotes you will not evaluate the expression so your querry will do

RE: [PHP-DB] MySQL/PHP Update

2002-03-28 Thread Jason
Emery [mailto:[EMAIL PROTECTED]] Sent: March 28, 2002 7:20 AM To: 'Jason'; Php-Db Subject: RE: [PHP-DB] MySQL/PHP Update Jason, this is intriguing. Please show us a bit more code before the mysql_query() call. -Original Message- From: Jason [mailto:[EMAIL PROTECTED]] Sent: Thursday, March

RE: [PHP-DB] MySQL, PHPand cron

2002-03-28 Thread Jonathan Hilgeman
First create the PHP script to connect to the database and empty the table (DELETE FROM table;) as if you were going to visit the page manually every time you wanted to empty the table. This shouldn't be too hard: ? // EmptyTable.php $dbLink = mysql_connect(host,user,pass);

RE: [PHP-DB] MySQL, PHPand cron

2002-03-28 Thread Gurhan Ozen
Hi Jenn, There are a couple ways you can do this. You can write a unix shell script and run it periodically at the cron. Here: #!/bin/mysql query=DELETE FROM tablename /usr/bin/mysql -u USER -pPASSWORD -D database -e $query And then you can just put this script into cron, see:

Re: [PHP-DB] MySQL/PHP Update

2002-03-27 Thread Maxwell
I'm trying to update my MySQL database, but it doesn't seem to be taking. my code is: mysql_query(update prod_list set prod_manu=$prod_man where sku='$prod'); Try: mysql_query(update prod_list set prod_manu='$prod_man' where sku='$prod'); Maxwell -- PHP Database Mailing List

Re: [PHP-DB] MySQL/PHP Update

2002-03-27 Thread Marius Ursache
Jason a écrit : I'm trying to update my MySQL database, but it doesn't seem to be taking. my code is: mysql_query(update prod_list set prod_manu=$prod_man where sku='$prod'); where prod_manu is an int $prod_man is an int sku is a varchar $prod is text mysql_query()

Re: [PHP-DB] MySQL and apostrophes, interesting problem. 42082

2002-03-10 Thread Robert Weeks
See the manual at php.net: addslashes() stripslashes() I've found it easier to just turn on magic-quotes in the php.ini file This is all covered at php.net Robert - Original Message - From: Nick Patsaros [EMAIL PROTECTED] To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]

Re: [PHP-DB] mysql and file upload problems

2002-03-09 Thread Robert Weeks
Why don't you just do the sql insert *after* the file upload function?: Pseudocode: if( NOT file upload attack, wrong file type, etc.){ //copy the file to the permanaent location //call function to insert file details into the database } else{ //echo error to user

Re: [PHP-DB] MySQL Result

2002-03-08 Thread DL Neil
Hi Chris I have delete working perfectly by doing the following: include(connectionstart.php); mysql_query (DELETE FROM emaillist WHERE EMail = '$email' ); However, how do I return a true or false flag whether the row was deleted or not? I basically need to know how to do a 0 or 1 I

Re: [PHP-DB] MySQL Result

2002-03-08 Thread Mike Maltese
mysql_affected_rows(int resource_id); This will return the number of rows that were affected by the last operation, so you could do something like this: if(mysql_affected_rows($connection) == 1){ //insert, update or delete succeeded }else{ //operation failed } - Original Message

Re: [PHP-DB] mysql connect, while and close big problem

2002-02-22 Thread Killer Angel Clark
non-persistent. I would also like to ask the difference between persistent and non-persistene connection? Ray Hunter [EMAIL PROTECTED] ¼¶¼g©ó¶l¥ó [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... What type of connections are you making persistent or non-persistent? Ray Hunter Firmware Engineer

RE: [PHP-DB] mysql connect, while and close big problem

2002-02-21 Thread Hunter, Ray
What type of connections are you making persistent or non-persistent? Ray Hunter Firmware Engineer ENTERASYS NETWORKS -Original Message- From: Killer Angel Clark [mailto:[EMAIL PROTECTED]] Sent: Thursday, February 21, 2002 10:17 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] mysql

Re: [PHP-DB] MySQL problem

2002-02-21 Thread Markus Lervik
On Fri, 2002-02-22 at 09:37, Caleb Walker wrote: I keep on getting this error statement: Warning: Supplied argument is not a valid MySQL result resource in /usr/local/www/data/phone/insert2.php on line 10 2 Can someone tell me what is wrong with the code below, I just cannot figure it

RE: [PHP-DB] MySQL/PHP date functions

2002-02-20 Thread Markus Lervik
On Wed, 2002-02-20 at 13:16, Sven Jacobs wrote: You can do it like this calculate the current day and extract 7 days of it ehm? extract 7 days of it? from what?-) I'm not quite following... then with an array the current day until the calculated day :-) ehm, call me stupid, but I didn't

RE: [PHP-DB] mysql LIMIT and ORDER BY problem

2002-02-20 Thread Rick Emery
it works for me. What do your data and table structures look like? -Original Message- From: Fredrik Wahlberg [mailto:[EMAIL PROTECTED]] Sent: Tuesday, February 19, 2002 4:55 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] mysql LIMIT and ORDER BY problem I have a strange problem with

RE: [PHP-DB] mysql and auto_increment

2002-02-20 Thread Gurhan Ozen
Yes you sure can,.. When you insert a row just use one of the older values that no longer exists on the table.. Alternatively, you can insert a blank value, mysql will automatically set it to the next value after the highest one in the table and then you can update it to one of the older values.

RE: [PHP-DB] mysql and auto_increment

2002-02-20 Thread Rick Emery
First, what do you mean by regs? If I understand your question, you want to know if mysql will re-use an old auto_increment value that has been deleted. The answer is yes and no. If you say: DELETE FROM mytable; then the next insertion will cause the auto_increment value to begin at 1 If you

RE: [PHP-DB] mysql and dropdown menus

2002-02-12 Thread Rick Emery
When you include $Select in your URL, did you remember to urlencode() it first? If no, the spaces will blow your URL away...very nasty... BTW, it helps if you post code. -Original Message- From: jeff akerman [mailto:[EMAIL PROTECTED]] Sent: Monday, February 11, 2002 4:27 PM To: [EMAIL

Re: [PHP-DB] mysql and dropdown menus

2002-02-12 Thread Philippe COLLEU
Jeff, I solved the problem by using a different frame for each drop down menu. In my case I had 5 drop down menus interacting together and selecting their values from the database. Then I'm passing the value of each variable to the other frames (affected by the selection) using a javascript

Re: [PHP-DB] mySQL dB copy

2002-02-11 Thread Jonathan Underfoot
If your not really a text MySQL guy I would highly recomend PHPMyAdmin. Its a set of PHP scripts you can upload into its own directory and run immediately. It will allow you to download (through the web interface) the entire database, and then move it to the new site (using the same tool.) I've

Re: [PHP-DB] MySQL / PHP Database Help

2002-02-08 Thread Jeroen Timmers
Hello, something that you can help is the follow try var_dump($newquery); then you see the complete query and run it in phpmyadmin. Jeroen - Original Message - From: Jonathan Underfoot [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, February 08, 2002 2:43 PM Subject: [PHP-DB]

RE: [PHP-DB] MySQL / PHP Database Help

2002-02-08 Thread Rick Emery
Yes, you can re-select from the same database without opeing a new connection. I recommend that you print the contents od $newquery to verify it contains the string you think it should. Perhaps the apostrophes you've enclosed the $row[] variable are not expanding. -Original Message-

Re: [PHP-DB] MySQL / PHP Database Help

2002-02-08 Thread DL Neil
Jonathan, I'm trying to write a script that checks for multiple entries on a table in a database. So far I've been plagued by MySQL errors. I'm fairly confident my scripting is ok (Then again, I've been wrong before.) I think moreover there might be some difficulty with my theory. Then

Re: [PHP-DB] MySQL / PHP Database Help

2002-02-08 Thread Jonathan Underfoot
What does bool(false) mean? Thats off the vardump -J - Original Message - From: Jeroen Timmers [EMAIL PROTECTED] To: Jonathan Underfoot [EMAIL PROTECTED] Cc: [PHP-DB] [EMAIL PROTECTED] Sent: Friday, February 08, 2002 8:58 AM Subject: Re: [PHP-DB] MySQL / PHP Database Help Hello

RE: [PHP-DB] MySQL / PHP Database Help

2002-02-08 Thread Rick Emery
, February 08, 2002 8:48 AM To: Jeroen Timmers Cc: [PHP-DB] Subject: Re: [PHP-DB] MySQL / PHP Database Help What does bool(false) mean? Thats off the vardump -J - Original Message - From: Jeroen Timmers [EMAIL PROTECTED] To: Jonathan Underfoot [EMAIL PROTECTED] Cc: [PHP-DB] [EMAIL PROTECTED

Re: [PHP-DB] MySQL / PHP Database Help

2002-02-08 Thread Jeroen Timmers
PROTECTED] Sent: Friday, February 08, 2002 3:47 PM Subject: Re: [PHP-DB] MySQL / PHP Database Help What does bool(false) mean? Thats off the vardump -J - Original Message - From: Jeroen Timmers [EMAIL PROTECTED] To: Jonathan Underfoot [EMAIL PROTECTED] Cc: [PHP-DB] [EMAIL PROTECTED

Re: [PHP-DB] MySQL / PHP Database Help

2002-02-08 Thread DL Neil
Jonathan, [have put the cc back to the list] Is it possible to make BOTH the date and venue into a single unique index? =Why not? Like a good woman, treat her right, and SQL will do almost anything for you: 6.5.3 CREATE TABLE Syntax CREATE [TEMPORARY] TABLE [IF NOT EXISTS] tbl_name

RE: [PHP-DB] MySQL

2002-02-04 Thread Richard Black
Easiest way is to download and install phpMyAdmin. http://phpmyadmin.sourceforge.net/ HTH Richy -Original Message- From: Morten Nielsen [SMTP:[EMAIL PROTECTED]] Sent: 04 February 2002 16:34 To: [EMAIL PROTECTED] Subject:[PHP-DB] MySQL Hi, Is there an easy way to see

Re: [PHP-DB] MySQL

2002-02-04 Thread Mike Maltese
Go download PHPMyAdmin. - Original Message - From: Morten Nielsen [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, February 04, 2002 8:34 AM Subject: [PHP-DB] MySQL Hi, Is there an easy way to see the data in a table? I made a table that contains information about people. How

RE: [PHP-DB] MySQL

2002-02-04 Thread Peter Lovatt
Lovatt [mailto:[EMAIL PROTECTED]] Sent: 04 February 2002 16:30 To: Morten Nielsen Subject: RE: [PHP-DB] MySQL phpMyAdmin! http://phpwizard.net/projects/phpMyAdmin/ HTH Peter --- Excellence in internet and open source software

Re: [PHP-DB] MySQL

2002-02-04 Thread Ken Thompson
I'm just learning MySQL and PHP so this fresh from my last snoop through the documentation, hope it will help. From the command line you can make a global query like - SELECT * FROM pets; and all the info stored in the table will be shown. To update a record use the update query: UPDATE pet

Re: [PHP-DB] MySQL connect

2002-02-04 Thread Ken Thompson
On Monday 04 February 2002 10:54 am, you wrote: Hi all, Ok I am learning this on my own but I could use some help. I have started these two pages test.php and config.php here is the code: test.php ? // include the database configuration include config.php; In looking at my include page

Re: [PHP-DB] MySQL connect

2002-02-04 Thread Paul Burney
on 2/4/02 12:54 PM, J Leonard at [EMAIL PROTECTED] appended the following bits to my mbox: mysql_connect($db[host],$db[user],$db[password],$db[database]) or The above function call only has three parameters. The database isn't specified in the connect call but selected later. Try:

RE: [PHP-DB] MySQL connect

2002-02-04 Thread Gurhan Ozen
mysql_connect() function only takes 3 arguments (servername, username, pass) . Select your database by using mysql_select_db() function... Try to rewrite the code as: mysql_connect($db[host],$db[user],$db[password]); mysql_select_db($db[database]); Refer to:

RE: [PHP-DB] MySQL Update command syntax

2002-02-01 Thread Rick Emery
Correct your example as follows: $sql = UPDATE $table_name SET new_area=\$new_area\; -Original Message- From: jas [mailto:[EMAIL PROTECTED]] Sent: Saturday, January 26, 2002 10:49 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] MySQL Update command syntax Could anyone help me out with the

Re: [PHP-DB] MySQL Connection Class

2002-01-30 Thread Dave Richardson
A number of connection classes and abstraction toolkits already exist. Your PHP 4.x install probably came with PEAR's DB.php abstraction layer. Save yourself the trouble perhaps? jas said: So all I would need to do is create a file named db_connection.php3 and put in the functions

Re: [PHP-DB] MySQL Connection Class

2002-01-30 Thread jas
Ok just to clear it up... our server is not running php4 unfortunately. =) Dave Richardson [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... A number of connection classes and abstraction toolkits already exist. Your PHP 4.x install probably came with PEAR's

RE: [PHP-DB] MySQL Connection Class

2002-01-30 Thread Gurhan Ozen
, Oracle, etc.) . Does this help??? Gurhan -Original Message- From: jas [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 30, 2002 12:33 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL Connection Class So all I would need to do is create a file named db_connection.php3 and put

Re: [PHP-DB] MySQL Connection Class

2002-01-30 Thread jas
Does this help??? Gurhan -Original Message- From: jas [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 30, 2002 12:33 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL Connection Class So all I would need to do is create a file named db_connection.php3 and put in the funct

Re: [PHP-DB] Mysql-class

2002-01-21 Thread Jason Wong
On Tuesday 22 January 2002 22:35, Johannes Hiemer wrote: First of all, please keep the discussion on the list! What did you want it to do? I want it to do things like inserting into Mysql-dbs Fetching arrays. Just every Mysql-command which Is also suported in PHP. What is it doing now?

Re: [PHP-DB] Mysql-class

2002-01-20 Thread Jason Wong
On Monday 21 January 2002 21:52, Johannes Hiemer wrote: Hi, i coded a Mysql-Class, there are no compiling-errors when i run it. But the problem is that it doesn´t do what i want it to do. I added the sourcecode below and would be happy for any sugestions how to make it better. [snip] What

Re: [PHP-DB] MySQL database

2002-01-19 Thread Miles Thompson
Morten, What's your level of knowledge of both databases and PHP? Please have a look at the Introductory Tutorial (Link at the top left of www.php.net). At the end of that tutorial, which is admittedly rudimentary, there are links to more advanced ones, including ones specifically for user

Re: [PHP-DB] MySQL database

2002-01-19 Thread Miles Thompson
As Brian Clark just pointed out on php-general, in response to another issue ... http://www.faqts.com/knowledge_base/index.phtml/fid/51/ Some very specific refernces. You'll find what you need there. Miles At 06:08 PM 1/19/2002 +0100, Morten Nielsen wrote: Hi, Could anybody explain to me how

Re: [PHP-DB] mySQL administration on Linux through NT

2002-01-16 Thread Miles Thompson
Jerry, For a command line interface, you can use either putty or TerraTermSSH. I prefer the former and it's available at http://www.chiark.greenend.org.uk/~sgtatham/putty/ . The latter is more Windows-ish. For a Windows-like interface, through a browser, there is phpMyAdmin, and others, but

RE: [PHP-DB] mySQL administration on Linux through NT

2002-01-16 Thread Howard Picken
If you're running a web server on your Linux box then simply download, install and use phpMyAdmin. All your management is then down through web pages. I use it all the time. HP -Original Message- From: Jerry [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 16 January 2002 10:48 PM To:

RE: [PHP-DB] MySQL Result Resource

2002-01-11 Thread matt stewart
shouldn't it be PASSWORD('madonna') ?? -Original Message- From: Necro [mailto:[EMAIL PROTECTED]] Sent: 11 January 2002 04:39 To: [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource http://www.hotscripts.com/Detailed/4219.html --- that is the script But I cannot use crypt

Re: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Miles Thompson
The use of the MD5 function in the query doesn't look quite right. Shouldn't it be MD5('$password') or MD5('$username'.'$password') if concatenating? Also, mysql_db_query() has been a deprecated function for some time now, mysql_query() is recommended. Hope this gets you going - Miles

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
argument is not a valid MySQL result resource in d:\htdocs\infekt\packages\auth.inc on line 104 Andrew -Original Message- From: Miles Thompson [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 2:05 AM To: Necro; [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL Result Resource

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Miles Thompson
MySQL result resource in d:\htdocs\infekt\packages\auth.inc on line 104 Andrew -Original Message- From: Miles Thompson [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 2:05 AM To: Necro; [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL Result Resource The use of the MD5 function

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
() ); $row = mysql_fetch_array($result); Andrew -Original Message- From: Miles Thompson [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 2:36 AM To: [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource Break up the code. I assume you are connecting to the database

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Miles Thompson
() ); $row = mysql_fetch_array($result); Andrew -Original Message- From: Miles Thompson [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 2:36 AM To: [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource Break up the code. I assume you are connecting to the database

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
-Original Message- From: Miles Thompson [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 3:08 AM To: Necro; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource Can you try this puppy at the MySQL console? I'd dearly love to know where andrewd is coming from, it sounds

Re: [PHP-DB] MySQL Result Resource

2002-01-10 Thread George Pitcher
[EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, January 10, 2002 4:09 PM Subject: RE: [PHP-DB] MySQL Result Resource Yep, andrewd is the username im trying to get this script to work with, its an authentication script.. The result of echo $arg is the following: select password, 1

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
PROTECTED] Subject: Re: [PHP-DB] MySQL Result Resource I was having something similar and solved it by wrapping the column names in parentheses: select password, 1 as auth from acl where (username='andrewd' and password=MD5(andrewd.madonna)); It might help. or eliminate something if I'm

Re: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Andrey Hristov
try this : select password, 1 as auth from acl where (username='andrewd' and password=MD5(andrewd.madonna)); - Original Message - From: Necro [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, January 10, 2002 6:18 PM Subject: RE: [PHP-DB] MySQL Result Resource Same error

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Miles Thompson
table 'andrewd' in where clause Andrew -Original Message- From: Miles Thompson [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 3:08 AM To: Necro; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource Can you try this puppy at the MySQL console? I'd dearly love to know

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
2002 3:28 AM To: Necro Cc: [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL Result Resource try this : select password, 1 as auth from acl where (username='andrewd' and password=MD5(andrewd.madonna)); - Original Message - From: Necro [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
[mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 3:29 AM To: Necro; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource LIGHT just came on!!! Why does ittake so long. MD5(andrew.madonna) - I think you're goint to have to do this $passhash = $username . $password and use MD5

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
- From: Miles Thompson [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 3:29 AM To: Necro; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource LIGHT just came on!!! Why does ittake so long. MD5(andrew.madonna) - I think you're goint to have to do this $passhash = $username

Re: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Andrey Hristov
try : $arg = select password, 1 as auth from acl where (username='andrewd') and password=MD5(concat(username,password)); HTH Andrey - Original Message - From: Necro [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, January 10, 2002 6:29 PM Subject: RE: [PHP-DB] MySQL Result

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread php3
Addressed to: Necro [EMAIL PROTECTED] [EMAIL PROTECTED] ** Reply to note from Necro [EMAIL PROTECTED] Fri, 11 Jan 2002 03:41:43 +1100 select password, 1 as auth from acl where (username='andrewd' and password=(163e06103a371fd95b21b4a849bb4b91))1064 : You have an error in your

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
username='andrewd' and password = 'PASSWORD(madonna)'Resource id #2 Any ideas? Andrew -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 8:56 AM To: Necro; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource Addressed to: Necro

Re: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Daniel Barton
: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 8:56 AM To: Necro; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource Addressed to: Necro [EMAIL PROTECTED] [EMAIL PROTECTED] ** Reply to note from Necro [EMAIL PROTECTED] Fri, 11 Jan 2002 03

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
either. Andrew -Original Message- From: Daniel Barton [mailto:[EMAIL PROTECTED]] Sent: Friday, 11 January 2002 2:40 PM To: Necro Cc: [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL Result Resource Andrew: Don't put quotes around your MySQL function call. i.e. PASSWORD($password

RE: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Necro
]] Sent: Friday, 11 January 2002 3:30 PM To: [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Result Resource Daniel, I had tried both with and without quotes. Neither work. Without quotes I get: select password, 1 as auth from acl where username='andrewd' and password = PASSWORD(madonna)1054

Re: [PHP-DB] MySQL Result Resource

2002-01-10 Thread Jason Wong
On Friday 11 January 2002 10:33, Necro wrote: Ok, I have tried to go to PASSWORD after none of the suggestions worked out. The current statement is: $arg = select password, 1 as auth from acl where username='$username' and password = 'PASSWORD($password)'; But the error I get now

RE: [PHP-DB] MySQL Password Writes but Doesn't Read!@#%^

2002-01-03 Thread Novotn Petr
Hello, Clear - coding has 16 characters - you have defined usrpassword in the second DB for 15 - probably one character is missing with coding. I am rather sure it is the problem, if not - sorry to disturb you Regards, Petr. -Original Message- From: Matthew Tedder [mailto:[EMAIL

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

2001-12-21 Thread Chris Payne
Hi there, I format my results using the following code: ? // format results by row while ($row = mysql_fetch_array($sql_result)) { $title = $row[title]; $desc = $row[description]; $image = $row[image]; $url = index3.php?image=.($row[image]); ? a href=?=$url??=$PHPSESSID?img

Re: [PHP-DB] Mysql result resource error

2001-12-20 Thread Jim Lucas
which one was giving you the problem? the first or second mysql try. if it was the second, try wrapping the $cattyname with single quotes like this Minor_Category = '$cattyname'. if the $cattyname var has anything but numbers, the statement won't work. Jim - Original Message - From:

RE: [PHP-DB] MySQL date formats

2001-12-20 Thread Rosser, Chris
nautilis, Leave the date in the database in MySQL format (/MM/DD) and when you need to display the date on your page, just do this: ?php explode(/, $datearray); $date = $datearray[2].'/'.$datearray[1].'/'.$datearray[0]; ? That just splits up the three numbers, and rearranges them. Easy

RE: [PHP-DB] MySQL date formats

2001-12-20 Thread Rosser, Chris
] Cc: 'nautilis' Subject: RE: [PHP-DB] MySQL date formats nautilis, Leave the date in the database in MySQL format (/MM/DD) and when you need to display the date on your page, just do this: ?php explode(/, $datearray); $date = $datearray[2].'/'.$datearray[1].'/'.$datearray

RE: [PHP-DB] MySQL date formats

2001-12-20 Thread Rick Emery
Try in PHP. This should take 12/25/2001 in $input_date and convert it to 20011225 in $db_date. Then write $db_date to mySQL database. Perform similar conversion when extracting from database. Or instruct your users to use MMDD. $thedate = explode(/,$input_date); //$thedate[0]=DD,

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

2001-12-20 Thread Bogdan Stancescu
A sample of what you were trying would have been helpful... If I understood your problem right, the solution is a piece of code like this: ? echo(table\ntr\n); while ($myrow=mysql_fetch_row($result)) { $colcount++; if ($colcount==$desiredcolcount) { $colcount=0; }

RE: [PHP-DB] Mysql result resource error

2001-12-20 Thread Shannon Doyle
of the same data. Its like it is doing each query three times or something. Don't know why it is doing that. - Shannon -Original Message- From: Jim Lucas [mailto:[EMAIL PROTECTED]] Sent: Friday, 21 December 2001 03:52 AM To: Shannon Doyle; [EMAIL PROTECTED] Subject: Re: [PHP-DB] Mysql

Re: [PHP-DB] MySQL: Reverse Order by???

2001-12-19 Thread Richard S. Crawford
ORDER BY field DESC At 07:27 AM 12/19/2001, Brian Grayless wrote: How you do a reverse order by in SQL, kind of like ORDER BY field only reverse the order??? Sliante, Richard S. Crawford http://www.mossroot.com AIM: Buffalo2K ICQ: 11646404 Y!: rscrawford MSN: [EMAIL PROTECTED] It is only

Re: [PHP-DB] MYSQL query help

2001-12-14 Thread Miles Thompson
It's not the IN, it's the sub-query you cannot use. MySQL doesn't support them and it's just about the main reason I don't like it. Alternatives? You could execute your subquery and return the results to an array. Loop through the array, using the index and the indexed element to drive a

Re: [PHP-DB] MySQL table recovery.

2001-12-06 Thread Jon Farmer
Is there a way to rollback a 'delete from table;' command in MySQL 3.23.36-1? Yes I did it... I pressed enter instead of backspace. Did I lost my table content? I have no backup of this especific database. PS: I didn't close the connection with the database yet. Thank for any help, even

Re: [PHP-DB] MySQL table recovery.

2001-12-06 Thread Bruno Gimenes Pereti
Pereti [EMAIL PROTECTED]; PHP-DB [EMAIL PROTECTED] Sent: Thursday, December 06, 2001 8:41 AM Subject: Re: [PHP-DB] MySQL table recovery. Is there a way to rollback a 'delete from table;' command in MySQL 3.23.36-1? Yes I did it... I pressed enter instead of backspace. Did I lost my table

Re: [PHP-DB] MySQL socket error

2001-11-30 Thread Dobromir Velev
Hi, Check if your MySQL server is working properly - this error usually appears when the MySQL server is down. The other thing is to check whether the socket the MySQL server uses is /tmp/mysql.sock and if it is not modify the php configuration variable MYSQL_SOCKET Hope this helps Dobromir

RE: [PHP-DB] MySQL Restarting A LOT

2001-11-20 Thread Matthew Loff
You have the wrong list. http://www.mysql.com/documentation/lists.html -Original Message- From: Jonathan Hilgeman [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 20, 2001 2:56 PM To: [EMAIL PROTECTED] Subject: [PHP-DB] MySQL Restarting A LOT Okay, this is beginning to bug. I

RE: [PHP-DB] MySQL Restarting A LOT

2001-11-20 Thread Jonathan Hilgeman
-Original Message- From: Matthew Loff [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 20, 2001 1:18 PM To: 'Jonathan Hilgeman'; [EMAIL PROTECTED] Subject: RE: [PHP-DB] MySQL Restarting A LOT You have the wrong list. http://www.mysql.com/documentation/lists.html -Original Message- From

Re: [PHP-DB] MySQL too many connection problems

2001-11-13 Thread Joshua Hoover
There is a setting when you launch MySQL to tell it how many connections it will accept. Read the following to get a better idea on this: http://www.mysql.com/doc/T/o/Too_many_connections.html The default number of connections to MySQL is 100, but can be set much higher if necessary. You

Re: [PHP-DB] MySQL too many connection problems

2001-11-13 Thread Lynn Siprelle
Many thanks, I'll let you know how it works out. Best, Lynn -- Lynn Siprelle, Siprelle Associates: Web Publishing Chief Assoc. Josephine b. 9/9/97 * New Assoc. Louisa b. 4/25/01 Business: lynn@siprelle com | Personal: [EMAIL PROTECTED] The New Homemaker: http://www.newhomemaker.com/ -- PHP

Re: [PHP-DB] mySQL LOAD DATA INFILE

2001-11-06 Thread Russ Michell
2 things: mysql_query($QueryInsert); print mysql_error(); Should read: $query = mysql_query($QueryInsert) or die(mysql_error()); and: It returns Can't get stat of '/www/publico2/tableData0TMRRy' (Errcode: 13). what exactly is: tableData0TMRRy?? if it should be a file, it should be

Re: [PHP-DB] MySQL: Alphabetizing title results in library format

2001-11-01 Thread Ian Evans
Petr Tuma wrote: What error message it produce? Ok, table titles is composed of: +--+-++ | titlesid | releaseyear | title | +--+-++ mysql select *,(case when title like 'The %' then substring (title, 5, 255)

RE: [PHP-DB] MySQL: Alphabetizing title results in library format

2001-11-01 Thread Cami
Message- From: Ian Evans [mailto:[EMAIL PROTECTED]] Sent: Thursday, November 01, 2001 9:20 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL: Alphabetizing title results in library format Petr Tuma wrote: What error message it produce? Ok, table titles is composed

Re: [PHP-DB] MySQL: Alphabetizing title results in library format

2001-11-01 Thread Ian Evans
Cami wrote: Try this: mysql select *,(case when title like '%The%' then substring (title, 5, 255) when title like '%A%' then substring (title, 3, 255) when title like '%An%' then substring (title, 4, 255) else title end) as sort_col from titles order by sort_col; Argh, that still produces

RE: [PHP-DB] MySQL: Alphabetizing title results in library format

2001-11-01 Thread Cami
what the manual say. Cami -Original Message- From: Ian Evans [mailto:[EMAIL PROTECTED]] Sent: Thursday, November 01, 2001 9:20 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] MySQL: Alphabetizing title results in library format Petr Tuma wrote: What error message it produce? Ok, table

Re: [PHP-DB] MySQL: Alphabetizing title results in library format

2001-11-01 Thread Petr Tuma
Hi, seems a bit strange. Try this select (use mysql client) mysql select title,if(title like 'The %','yes','no') from titles; if it works try substring functions and if that works try 'order by' clause. It's at least working on server v. 3.23, so in case it will not work find out in the 'list

Re: [PHP-DB] MySQL: Alphabetizing title results in library format

2001-10-31 Thread Ian Evans
Petr Tuma wrote: select *,(case when Title like 'The %' then substring (Title, 5, 255) ETC. Alas, MySQL doesn't like that syntax either. :( -- Ian Evans Digital Hit Entertainment - News and Information http://www.digitalhit.com -- PHP Database Mailing List (http://www.php.net/) To

RE: [PHP-DB] mySQL table update

2001-10-29 Thread Niklas Lampén
I have a problem here which I can not find an answer. My date fields (EmailD in this case) can be in four different formats: a) dd.mm. b) d.mm. c) dd.m. d) d.m. So this is what I've tried to do to convert the dates to -mm-dd format: INSERT INTO feCompsT (ID, Company,

<    3   4   5   6   7   8   9   10   >