[PHP-DB] Re: Construct, Q+E, QBE

2002-07-18 Thread Dan Koken
I migrated from informix some years back. This is much easier to do in PHP / mySQL than in informix, and in fact is something that is quite commonly done. Since you can create sql commands as a string, you can put together a string just about anyway you want based on conditions users enter in

[PHP-DB] How to use Full text search?

2002-07-18 Thread Dasmeet Singh
I am developing a site which shows tv schedules online... http://www.einFotimes.com I want to add search to it. Basically i want to know how to full text search through all the tables in database and i also want the name of table in result along with fields...is it possible? Dasmeet -- PHP

Re: [PHP-DB] How to use Full text search?

2002-07-18 Thread Martin Clifford
The query you would need would be something along the lines of: SELECT show_name FROM table_of_shows WHERE show_name LIKE '%$keyword%' Learning the LIKE syntax is going to be the best help to you in this situation, I believe ;o) Martin Clifford Homepage: http://www.completesource.net

Re: [PHP-DB] How to use Full text search?

2002-07-18 Thread Dasmeet Singh
Martin Clifford wrote: The query you would need would be something along the lines of: SELECT show_name FROM table_of_shows WHERE show_name LIKE '%$keyword%' Learning the LIKE syntax is going to be the best help to you in this situation, I believe ;o) Thanx, I am already using 'Like'

Re: [PHP-DB] How to use Full text search?

2002-07-18 Thread Jeffrey_N_Dyke
I break up the search words using a function and then build a query based on the search criteria. If it is multiple words, I use REGEXP for the search.( I use a mysql database). then when there are multiple searches you can format the query string like SELECT show_name FROM table_of_shows

Re: [PHP-DB] How to use Full text search?

2002-07-18 Thread Miles Thompson
What database is being used? How is the target structured and are there indexes to use? My concern with this approach, though I don't have a better one, is that it will be deathly slow as the database grows. I'd suggest a double check of the database documentation. Just a couple of random

RE: [PHP-DB] TEXTAREA ...

2002-07-18 Thread José Moreira
good day/afternoon/night why do i get this : $content = htmlentities($content);br / when i insert this : $content = htmlentities($content);[new line] using this : $thePost = nl2br(addslashes(htmlspecialchars($HTTP_POST_VARS[POST]))); when i want this : $content

[PHP-DB] multiple selections to input variables

2002-07-18 Thread Terry Romine
I have a form with a multi-line select field: select name=cities size=5 multiple ? $sql=select City from table group by City ;

Re: [PHP-DB] TEXTAREA ...

2002-07-18 Thread Jason Wong
On Thursday 18 July 2002 23:18, José Moreira wrote: using this : $thePost = nl2br(addslashes(htmlspecialchars($HTTP_POST_VARS[POST]))); when i want this : $content = htmlentities($content);br and i sometimes get br /br / RTFM -- Jason Wong - Gremlins Associates -

Re: [PHP-DB] multiple selections to input variables

2002-07-18 Thread Jason Wong
On Thursday 18 July 2002 23:18, Terry Romine wrote: I have a form with a multi-line select field: select name=cities size=5 multiple Use: select name=cities[] size=5 multiple if($cities) { // multiple may be selected -- figure that out later

RE: [PHP-DB] TEXTAREA ...

2002-07-18 Thread José Moreira
RTFM ??? -Mensagem original- De: Jason Wong [mailto:[EMAIL PROTECTED]] Enviada: quinta-feira, 18 de Julho de 2002 16:24 Para: [EMAIL PROTECTED] Assunto: Re: [PHP-DB] TEXTAREA ... On Thursday 18 July 2002 23:18, José Moreira wrote: using this : $thePost =

RE: [PHP-DB] TEXTAREA ...

2002-07-18 Thread Hillensbeck, Preston
Why even bother replying if that is all you have to say? -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED]] Sent: Thursday, July 18, 2002 10:24 AM To: [EMAIL PROTECTED] Subject: Re: [PHP-DB] TEXTAREA ... On Thursday 18 July 2002 23:18, José Moreira wrote: using this :

Re: [PHP-DB] How to use Full text search?

2002-07-18 Thread Dasmeet Singh
Miles Thompson wrote: What database is being used? How is the target structured and are there indexes to use? My concern with this approach, though I don't have a better one, is that it will be deathly slow as the database grows. I'd suggest a double check of the database

Re: [PHP-DB] How to use Full text search?

2002-07-18 Thread Miles Thompson
At 07:29 PM 7/18/2002 +0530, Dasmeet Singh wrote: Miles Thompson wrote: What database is being used? How is the target structured and are there indexes to use? My concern with this approach, though I don't have a better one, is that it will be deathly slow as the database grows. I'd suggest a

RE: [PHP-DB] TEXTAREA ...

2002-07-18 Thread Hillensbeck, Preston
Well have you thought about that maybe someone went looking for the documentation and couldn't find what they were looking for? Maybe if you get your _head_ out of your _ass_ and stop being a prick, maybe you would see that. -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED]]

RE: [PHP-DB] TEXTAREA ...

2002-07-18 Thread Hillensbeck, Preston
Don't tell me what to do, I'll do as I please thank you very little. -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED]] Sent: Thursday, July 18, 2002 12:36 PM To: Hillensbeck, Preston Subject: Re: [PHP-DB] TEXTAREA ... Please do not include me in any reply. I'm subscribed

[PHP-DB] Problem with retrieving Data with MySQL

2002-07-18 Thread Blaine D. Dinsmore
Can somone tell me what is wrong with my code here? My e-mail does not mail me the results from the the latest database entry: // // Mail Handler Routine / function mailer($issue,$host,$sql){

Re: [PHP-DB] multiple selections to input variables

2002-07-18 Thread Terry Romine
Great!! Works like a charm. Terry On Thursday, July 18, 2002, at 10:27 AM, Jason Wong wrote: On Thursday 18 July 2002 23:18, Terry Romine wrote: I have a form with a multi-line select field: select name=cities size=5 multiple Use: select name=cities[] size=5

Re: [PHP-DB] TEXTAREA ...

2002-07-18 Thread Jason Wong
On Friday 19 July 2002 01:44, Hillensbeck, Preston wrote: Well have you thought about that maybe someone went looking for the documentation and couldn't find what they were looking for? Did the OP tell you that? Let him/her speak for himself/herself. Maybe if you get your _head_ out of

RE: [PHP-DB] TEXTAREA ...

2002-07-18 Thread Woolsey, Fred
Guys, My instincts tell me to keep out of this spat, but what the hey... 1) Perhaps it is wise not to make gratuitous, patronizing replies, such as RTFM, to requests for information. Better to let the question pass and keep your thoughts to yourself. 2) Perhaps it is wise not to use words

Re: [PHP-DB] Problem with retrieving Data with MySQL

2002-07-18 Thread Maureen
It might help if you send the list an indication of what $sql (the query) looks like. The only thing it appears to be returning is what was initially sent to the function. Maureen Blaine D. Dinsmore [EMAIL PROTECTED] said: Can somone tell me what is wrong with my code here? My e-mail

Re: [PHP-DB] Problem with retrieving Data with MySQL

2002-07-18 Thread Blaine D. Dinsmore
$sql = SELECT probid,loggerid,DATE_FORMAT(logdate,'%m-%d-%Y') AS date, . priority,interface,screen,descript,notes . FROM bugs WHERE probid='$issue'; Maureen [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... It might help if you send the list an

[PHP-DB] or statement in url

2002-07-18 Thread Matthew K. Gold
can I use an OR operator in a variable that is passed through a url? ex. how can I combine the following two lines so that I end up with records that have an id of either 1 or 2? http://www.xyz.com/foo.php?FooID=1 http://www.xyz.com/foo.php?FooID=2 (I tried the following, but it didn't work:

[PHP-DB] Best way to have virtual objects do something?

2002-07-18 Thread Leif K-Brooks
First of all, I'm sorry if the php general list would be a better place to do this. Anyway, I am making a game website with a friend. Among other things, it will have virtual objects that can be used to do things. My database structure idea is something like: item_actions(id

Re: [PHP-DB] or statement in url

2002-07-18 Thread Martin Clifford
Pass different variables and use them both in your query. http://www.xyz.com/foo.php?FooID=1 http://www.xyz.com/foo.php?Foo2ID=2 $query = SELECT * FROM table WHERE id=$FooID OR id=$Foo2ID; HTH Martin Clifford Homepage: http://www.completesource.net Developer's Forums:

Re: [PHP-DB] Problem with retrieving Data with MySQL

2002-07-18 Thread Maureen
First of all, the function mysqlconn does not exist (unless you created it in your script). There is mysql_connect, where you pass the connection parameters for the database, ie. hostname, username, password, etc. Then you query the database with mysql_query($sql). There is also just

Re: [PHP-DB] Problem with retrieving Data with MySQL

2002-07-18 Thread Maureen
I was wrong, you can use DATE_FORMAT in the sql query. I usually format it after I take it out, using php. I apologize. Maureen [EMAIL PROTECTED] said: First of all, the function mysqlconn does not exist (unless you created it in your script). There is mysql_connect, where you pass

Re: [PHP-DB] or statement in url

2002-07-18 Thread Steve Cayford
How about http://www.xyz.com/foo.php?FooID[]=1FooID[]=2 Then FooID will be an array of the values. -Steve On Thursday, July 18, 2002, at 03:20 PM, Matthew K. Gold wrote: can I use an OR operator in a variable that is passed through a url? ex. how can I combine the following two lines so

[PHP-DB] Debugging/monitoring traffic to MySQL

2002-07-18 Thread Clive Bruton
Is there a way to see the traffic between PHP and MySQL, ie see the statements/raw data that is sent between the two processes. I've tried running the MYSQL client, but there doesn't seem to be any obvious command to do this. Some other terminal process? I'm running MacOS X. TIA. -- Clive

RE: [PHP-DB] or statement in url

2002-07-18 Thread Beau Lebens
or alternatively just do something similar to what you did, using either the in-built array handling, or your own string manipulation ie. http://url.com/page.php?var1=foo http://url.com/page.php?var1=bar could be either; http://url.com/page.php?var[]=foovar[]=bar ($_GET[var] will be an array

[PHP-DB] Searching...

2002-07-18 Thread Georgie Casey
in ym search page, i construct a sql query from user input to search my database, and i run this query to get totalresults. Then run another query with a LIMIT 0, 30 ending for each page. So I'm running 2 mySQL queries per page. My question is, is this inefficient? is there any better way i dont

[PHP-DB] Fatal error: Call to undefined function: pg_connect() in .....

2002-07-18 Thread Vincent
Hi, I'm a newbie here. I don't know what went wrong. I've tried searching for solutions and can't find any. How come pg_connect() isn't defined? Should I include any header files or something in php? Here's my code: HTML HEAD TITLEExample PHP Querying/TITLE BODY ?php $conn =

Re: [PHP-DB] Fatal error: Call to undefined function: pg_connect() in .....

2002-07-18 Thread Miles Thompson
Is PostgreSQL started with the -i switch? (I think that's the one; it exposes it to tcp/ip connections.) Check your PGSQL docs to be certain. Have you run a page with phpinfo? Is PostgreSQL support compiled into your installation of PHP? This is a file consisting of ? phpinfo(); ?, named

Re: [PHP-DB] Debugging/monitoring traffic to MySQL

2002-07-18 Thread colbey
On the MySQL server (could be the same machine) start mysql with -l arguement. Which enables connection and query logging.. YOu can just sit there and tail -f the server.log file to see all the querys/connections being executed in realtime... good look reading anything on a busy server ;)

Re: [PHP-DB] Debugging/monitoring traffic to MySQL

2002-07-18 Thread Edward Marczak
On 7/18/02 8:30 PM, Clive Bruton [EMAIL PROTECTED] wrote: Is there a way to see the traffic between PHP and MySQL, ie see the statements/raw data that is sent between the two processes. I've tried running the MYSQL client, but there doesn't seem to be any obvious command to do this. Some

[PHP-DB] Re: Searching...

2002-07-18 Thread David Robley
In article [EMAIL PROTECTED], [EMAIL PROTECTED] says... in ym search page, i construct a sql query from user input to search my database, and i run this query to get totalresults. Then run another query with a LIMIT 0, 30 ending for each page. So I'm running 2 mySQL queries per page. My