Re: [PHP] how to select files from a directory and transfer to a different dir ?

2005-02-23 Thread Richard Lynch
Vaibhav Sibal wrote: > I need to select around 200 files at random out of a file pool of > 10k-15k files from a directory and then transfer them to another > directory on my linux server which runs Apache 2.0.52, PHP 5.0.3 and > Mysql. I will also be requiring to add the paths of all those files >

[PHP] how to select files from a directory and transfer to a different dir ?

2005-02-22 Thread Vaibhav Sibal
Hello, I need to select around 200 files at random out of a file pool of 10k-15k files from a directory and then transfer them to another directory on my linux server which runs Apache 2.0.52, PHP 5.0.3 and Mysql. I will also be requiring to add the paths of all those files into a database. If some

Re: [PHP] How to Select multiples tables of different database in one query

2004-09-01 Thread Frédéric Hardy
Warning 2 : it is a mysql example. Whith other DBM, i don't know how to do that, but i think that its exactly the same thing. PHP version : mysql_query($query). Fred. Tariq Murtaza wrote: *Hi All,* Can someone elaborate on How to Select multiples tables of different database in one query, pertic

Re: [PHP] How to Select multiples tables of different database in one query

2004-09-01 Thread Frédéric Hardy
Not difficult : database db1 database db2 database db3 select db1.table3.column2, db2.table5.column1, db3.table1.column7 FROM db1.table3, db2.table5, db3.table1; You can use alias in FROM on table like this : select alias1.column2, alias2.column1, alias3.column7 FROM db1.table3 AS alias1, db2.ta

[PHP] How to Select multiples tables of different database in one query

2004-09-01 Thread Tariq Murtaza
Hi All, Can someone elaborate on How to Select multiples tables of different database in one query, perticularly when using php as scripting language. Regards TM -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] How to Select

2003-08-15 Thread Marek Kilimajer
$news = mysql_query("select StudentId FROM $table"); if($mydata=mysql_fetch_object($news)) { //got it } else { // no such StudentId } John Taylor-Johnston wrote: Ok, this is a basic MySQL question, but I don't know how to code it in PHP. I want to check in StudentId. If it exists,

Re: [PHP] How to Select

2003-08-15 Thread Kae Verens
John Taylor-Johnston wrote: Ok, this is a basic MySQL question, but I don't know how to code it in PHP. I want to check in StudentId. If it exists, ... Anyone good humoured who would help me fill in the blank. Like I should know this, but haven't even thought of coding SQL in a while :) $myconnec

[PHP] How to Select

2003-08-14 Thread John Taylor-Johnston
Ok, this is a basic MySQL question, but I don't know how to code it in PHP. I want to check in StudentId. If it exists, ... Anyone good humoured who would help me fill in the blank. Like I should know this, but haven't even thought of coding SQL in a while :) $myconnection = mysql_connect($serve

Re: [PHP] how to select a file on a random basis?

2002-05-20 Thread The_RadiX
ent #: 04475739 ::: - Original Message - From: "Craig Vincent" <[EMAIL PROTECTED]> To: "Andy" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Monday, May 20, 2002 6:18 PM Subject: RE: [PHP] how to select a file on a random basis? > > I would like to pick a file

RE: [PHP] how to select a file on a random basis?

2002-05-20 Thread Craig Vincent
> I would like to pick a file out of a directory by random. There are 400 > files and I just want to pick on of those by random. > > Is there a way with rand() and file ? Well there's a couple ways you could do this...it's too early in the morning to post code but with some quick searches in the

[PHP] how to select a file on a random basis?

2002-05-19 Thread Andy
Hi there, I would like to pick a file out of a directory by random. There are 400 files and I just want to pick on of those by random. Is there a way with rand() and file ? Thanx for any hint, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/

RE: [PHP] How to select a line from a web page source?

2001-07-11 Thread Remo Pini
The simplest way I could think of would be to use a regex: /^(.*Jim.*)$/g (g=global) and then using $1 (the content of the parenthesis), this would give you the whole line containing "Jim". Greets, remo ps: is perl syntax, needs to be adjusted for php... > Hi there: > > I wanna select a line

[PHP] How to select a line from a web page source?

2001-07-10 Thread Luis Simoes
Hi there: I wanna select a line from a table which is in a php page resulted of a mysql_query So far what i have is a way to search the text from only line and then limit the characters in substr ( ) Thats a really wierd way to do it, i think, and my problem its the page im trying to do its a te

Re: [PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread James Holloway
*Shrug* Don't have time to test at the moment... That was taken from Chapter 9.3.4.7 of the MySQL manual http://www.mysql.com/doc/P/a/Pattern_matching.html Prior to MySQL Version 3.23.4, REGEXP is case sensitive, and the previous query will return no rows. To match either lowercase or upper

RE: [PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread Don Read
On 23-May-01 Bass¨Ð¦õªv wrote: > Hi , > By defualt , select rows from Mysql is case insenstive . > For exmaple , > select * from foo where name = 'PHP' > select * from foo where name = 'php' > is the same > > how can i do a queny which > select * from foo where name = 'PHP' > is success > but >

Re: [PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread Martín Marqués
On Mié 23 May 2001 17:56, you wrote: > Hey try this, though there are probably better ways, > > "SELECT * FROM foo WHERE name REGEXP '^[PHP]'"; This is not SQL compatible. This would be a correct SQL statement: SELECT * FROM foo WHERE name LIKE "[PHP]%" Saludos... :-) -- Cualquiera administra

Re: [PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread James Holloway
Hey try this, though there are probably better ways, "SELECT * FROM foo WHERE name REGEXP '^[PHP]'"; James ""Bass¨Ð¦õªv"" <[EMAIL PROTECTED]> wrote in message 9egfot$cfu$[EMAIL PROTECTED]">news:9egfot$cfu$[EMAIL PROTECTED]... > Hi , > By defualt , select rows from Mysql is case insenstive . > F

Re: [PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread Martín Marqués
On Mié 23 May 2001 17:11, Tiago Moitinho wrote: > Try > > SELECT * FROM foo WHERE strcmp('PHP', name) = 0; This is horrable!! Doesn't MySQL have PCRE? -- Cualquiera administra un NT. Ese es el problema, que cualquiera administre. -

Re: [PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread Martín Marqués
On Mié 23 May 2001 16:54, Bass¨Ð¦õªv wrote: > Hi , > By defualt , select rows from Mysql is case insenstive . > For exmaple , > select * from foo where name = 'PHP' > select * from foo where name = 'php' > is the same > > how can i do a queny which > select * from foo where name = 'PHP' > is succe

RE: [PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread Tiago Moitinho
Try SELECT * FROM foo WHERE strcmp('PHP', name) = 0; > -Original Message- > From: Bass¨Ð¦õªv [mailto:[EMAIL PROTECTED]] > Sent: quarta-feira, 23 de Maio de 2001 14:55 > To: [EMAIL PROTECTED] > Subject: [PHP] How to select rows from Mysql with case sens

[PHP] How to select rows from Mysql with case senstive ??

2001-05-23 Thread Bass¨Ð¦õªv
Hi , By defualt , select rows from Mysql is case insenstive . For exmaple , select * from foo where name = 'PHP' select * from foo where name = 'php' is the same how can i do a queny which select * from foo where name = 'PHP' is success but select * from foo where name = 'php' fail ?? given that