php-general Digest 21 Jul 2010 13:05:01 -0000 Issue 6857

2010-07-21 Thread php-general-digest-help
php-general Digest 21 Jul 2010 13:05:01 - Issue 6857 Topics (messages 307040 through 307062): exec output to mySQL, How? 307040 by: Tom Sparks 307050 by: Nilesh Govindarajan 307053 by: Per Jessen 307055 by: Tom Sparks 307056 by: Nilesh Govindarajan

php-general Digest 22 Jul 2010 02:35:11 -0000 Issue 6858

2010-07-21 Thread php-general-digest-help
php-general Digest 22 Jul 2010 02:35:11 - Issue 6858 Topics (messages 307063 through 307081): Re: PDO and UPDATE problem 307063 by: Peter Lind ƒÈ|²¿|Éó|Ӌ|Óë|ƒÈ|¿Ø|ïL|ëU|¹Ü|Àí 307064 by: bftvetq Question about SQL and Graph nodel trees 307065 by: Tim Gallagher

Re: [PHP] exec output to mySQL, How?

2010-07-21 Thread Nilesh Govindarajan
On Wed, Jul 21, 2010 at 8:49 AM, Tom Sparks tom_a_spa...@yahoo.com.au wrote: How do I take the output from a command line program and update a MYSQL database with it? tom_a_sparks Light travels faster then sound, which is why some people appear bright, until you hear them speak --

Re: [PHP] eval and HEREDOC

2010-07-21 Thread Peter Lind
On 21 July 2010 06:46, Sorin Buturugeanu m...@soin.ro wrote: @Vincent: no, the short tags are not off. @Jim: This seamns to work fine: $template = file_get_contents(pathTemplates.$this-dir.$this-tpl); ob_start(); $template = eval('?'.$template); $template = ob_get_clean(); Thanks! Best

Re: [PHP] MySQL select matching

2010-07-21 Thread Simcha Younger
On Mon, 19 Jul 2010 10:36:40 -0600 Ashley M. Kirchner ash...@pcraft.com wrote: mysql select * from table where id='1'; +---+-+-+---+ | 1 | 123 | 0.0 | C | | 1 | 234 | 0.1 | D | | 1 | 345 | 0.0 | D | | 1 | 456 | 0.1 | C | | 1 | 567 | 0.1 | G |

Re: [PHP] exec output to mySQL, How?

2010-07-21 Thread Per Jessen
Tom Sparks wrote: How do I take the output from a command line program and update a MYSQL database with it? command line program | mysql -u user -p -Ddatabase -- Per Jessen, Zürich (22.6°C) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] eval and HEREDOC

2010-07-21 Thread Sorin Buturugeanu
Hi Peter! In the first version of the template engine I had markers but now I need more complex conditions or operations inside the template files, like array of arrays and so on. I really like the freedom to be able to just open a PHP tag ? ? and use a foreach() or whatever PHP function as I

Re: [PHP] exec output to mySQL, How?

2010-07-21 Thread Tom Sparks
--- On Wed, 21/7/10, Nilesh Govindarajan li...@itech7.com wrote: On Wed, Jul 21, 2010 at 8:49 AM, Tom Sparks tom_a_spa...@yahoo.com.au wrote: How do I take the output from a command line program and update a MYSQL database with it? tom_a_sparks Light travels faster then sound, which is

Re: [PHP] exec output to mySQL, How?

2010-07-21 Thread Nilesh Govindarajan
On Wed, Jul 21, 2010 at 12:29 PM, Per Jessen p...@computer.org wrote: Tom Sparks wrote: How do I take the output from a command line program and update a MYSQL database with it? command line program | mysql -u user -p -Ddatabase -- Per Jessen, Zürich (22.6°C) -- PHP General Mailing

Re: [PHP] exec output to mySQL, How?

2010-07-21 Thread Nilesh Govindarajan
On Wed, Jul 21, 2010 at 12:39 PM, Tom Sparks tom_a_spa...@yahoo.com.au wrote: --- On Wed, 21/7/10, Nilesh Govindarajan li...@itech7.com wrote: On Wed, Jul 21, 2010 at 8:49 AM, Tom Sparks tom_a_spa...@yahoo.com.au wrote: How do I take the output from a command line program and update a MYSQL

[PHP] MySQL+PHP

2010-07-21 Thread Diana Wu
Dear all, I'm a newbie, need your help. Now I am building a databasea using MySQL and PHP, I want to put two tables in one searching, the two are in one database. $query = SELECT SQL_CALC_FOUND_ROWS * FROM table1 WHERE .implode( AND , $data); $number = SELECT FOUND_ROWS(); How can I

Re: [PHP] exec output to mySQL, How?

2010-07-21 Thread Ashley Sheridan
On Wed, 2010-07-21 at 12:57 +0530, Nilesh Govindarajan wrote: On Wed, Jul 21, 2010 at 12:29 PM, Per Jessen p...@computer.org wrote: Tom Sparks wrote: How do I take the output from a command line program and update a MYSQL database with it? command line program | mysql -u user -p

Re: [PHP] exec output to mySQL, How?

2010-07-21 Thread Per Jessen
Nilesh Govindarajan wrote: On Wed, Jul 21, 2010 at 12:29 PM, Per Jessen p...@computer.org wrote: Tom Sparks wrote: How do I take the output from a command line program and update a MYSQL database with it? command line program | mysql -u user -p -Ddatabase I don't think this is what he

RE: [PHP] php array in different OS

2010-07-21 Thread Bob McConnell
From: fyang I have a simple test code in different OS ,but it give me a different result. the code as follows: ?php $n= 5; for($i=0;$i$n;$i++) { $data[]=array(,$i,$i/1000); echo $i, ,$data[$i][1],br; }

[PHP] PDO and UPDATE problem

2010-07-21 Thread Sky Gunning
Hello I have a problem with a update using PDO. (learning atm and updating a php class to use PDO) private function updateUser($id) { $date = mktime(); $DB = Db::getInstance(); $stmt = $DB-prepare('UPDATE '. TBL_USERS .' SET date_last_action=:updateDate WHERE

Re: [PHP] PDO and UPDATE problem

2010-07-21 Thread Peter Lind
On 21 July 2010 15:04, Sky Gunning sky.gunn...@gmail.com wrote: Hello I have a problem with a update using PDO. (learning atm and updating a php class to use PDO)    private function updateUser($id)    {        $date = mktime();        $DB = Db::getInstance();        $stmt =

[PHP] ��|部|审|��|与|��|控|�L|�U|管|理

2010-07-21 Thread bftvetq
下午 10:04:12;ZFWAR3WSDGT4WE633E63XG 内 部 审 计 及 内 部 控 制 与 财 务 风 险 管 理 时 间:2010年7月29-30日(上 海) 时 间:2010年8月06-07日(深 圳) ◆参课对象: 董事会、监事会成员;负责内部控制和内部审计部门的经理 、主管;总经理、财务副总经理以及其他高级经营管理人员;财务总监、财 务经理、财务主管、税务经理、税务主管、总帐会计、税务会计等具体操 作人士。 ◆说

[PHP] Question about SQL and Graph nodel trees

2010-07-21 Thread Tim Gallagher
I cannot be the only one that is having this problem, what are you using for DAG (Direct Acrylic Graph)? I need to have a mesh node edge graph and am having trouble with this? I see that Neo4j has a rest server and I can do this in Java but I want to do it in PHP with a MYSQL or postgresql.

[PHP] Extending Exception

2010-07-21 Thread Christoph Boget
Ok, so taking the sample code that is on the page http://us3.php.net/manual/en/language.exceptions.extending.php Literally, just cutting and pasting the code. When I try to throw new Exception( 'My Message' ); PHP spits out the following fatal error: Fatal error: Wrong parameters for

Re: [PHP] Extending Exception

2010-07-21 Thread Ashley Sheridan
On Wed, 2010-07-21 at 11:10 -0400, Christoph Boget wrote: Ok, so taking the sample code that is on the page http://us3.php.net/manual/en/language.exceptions.extending.php Literally, just cutting and pasting the code. When I try to throw new Exception( 'My Message' ); PHP spits out

Re: [PHP] Extending Exception

2010-07-21 Thread Richard Quadling
On 21 July 2010 16:10, Christoph Boget jcbo...@hotmail.com wrote: Ok, so taking the sample code that is on the page http://us3.php.net/manual/en/language.exceptions.extending.php Literally, just cutting and pasting the code.  When I try to throw new Exception( 'My Message' ); PHP spits

Re: [PHP] Extending Exception

2010-07-21 Thread Richard Quadling
On 21 July 2010 16:14, Ashley Sheridan a...@ashleysheridan.co.uk wrote: On Wed, 2010-07-21 at 11:10 -0400, Christoph Boget wrote: Ok, so taking the sample code that is on the page http://us3.php.net/manual/en/language.exceptions.extending.php Literally, just cutting and pasting the code.  

Re: [PHP] Question about SQL and Graph nodel trees

2010-07-21 Thread Andrew Ballard
On Wed, Jul 21, 2010 at 11:04 AM, Tim Gallagher tgallag...@danati.com wrote: I cannot be the only one that is having this problem, what are you using for DAG (Direct Acrylic Graph)?  I need to have a mesh node edge graph and am having trouble with this?  I see that Neo4j has a rest server and

Re: [PHP] Extending Exception

2010-07-21 Thread Richard Quadling
On 21 July 2010 16:30, Christoph Boget jcbo...@hotmail.com wrote: [1] http://us3.php.net/manual/en/migration53.new-features.php Thanks for this.  And thanks for your explanation.  I think it would have been nice for there to have been some mention anywhere near/around example #2 on 

[PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Dotan Cohen
Take for example: INSERT INTO table ( field ) VALUES ('{$variable}' ) Why the curly brackets? Where in the fine manual is this addressed? I started from [1] but did not find the relevant info. [1] http://il2.php.net/manual/en/book.mysql.php -- Dotan Cohen http://gibberish.co.il

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Daniel Brown
On Wed, Jul 21, 2010 at 14:59, Dotan Cohen dotanco...@gmail.com wrote: Take for example: INSERT INTO table ( field ) VALUES ('{$variable}' ) Why the curly brackets? Where in the fine manual is this addressed? I started from [1] but did not find the relevant info. [1]

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Dotan Cohen
On Wed, Jul 21, 2010 at 22:07, Daniel Brown danbr...@php.net wrote:    That's just basic variable parsing on the PHP side, it's not MySQL-specific.  Check out the variable parsing heading at http://php.net/string . Thanks, Daniel. It seems unnecessary, then, as the quote character is not a

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Nathan Nobbe
On Wed, Jul 21, 2010 at 1:17 PM, Dotan Cohen dotanco...@gmail.com wrote: On Wed, Jul 21, 2010 at 22:07, Daniel Brown danbr...@php.net wrote: That's just basic variable parsing on the PHP side, it's not MySQL-specific. Check out the variable parsing heading at http://php.net/string .

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Dotan Cohen
On Wed, Jul 21, 2010 at 22:27, Nathan Nobbe quickshif...@gmail.com wrote: the single quote is not part of the variable name in the example you posted and further more the curly braces won't be evaluated as part of a variable name unless the string expression is wrapped in double quotes (which

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Nathan Nobbe
On Wed, Jul 21, 2010 at 1:32 PM, Daniel Brown danbr...@php.net wrote: On Wed, Jul 21, 2010 at 15:27, Nathan Nobbe quickshif...@gmail.com wrote: [snip!] name unless the string expression is wrapped in double quotes (which probly also evaluates in heredocs nowdocs). [snip!] Close.

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Daniel Brown
On Wed, Jul 21, 2010 at 15:27, Nathan Nobbe quickshif...@gmail.com wrote: [snip!] name unless the string expression is wrapped in double quotes (which probly also evaluates in heredocs nowdocs). [snip!] Close. HEREDOC, yes. NOWDOC, no. There's zero parsing done on NOWDOC strings. --

RE: [PHP] Question about SQL and Graph nodel trees

2010-07-21 Thread Tim Gallagher
Thank you for the informaiton. I did see that code but it looks like it is formatted for MSSQL and was unable to get it to work for Mysql. Tim From: Andrew Ballard [aball...@gmail.com] Sent: Wednesday, July 21, 2010 11:40 AM To: Tim Gallagher Cc:

Re: [PHP] php array in different OS

2010-07-21 Thread fyang
Dear Bob McConnell, Thank you for your reply. I really post the same message eight times because of the first e-mail authentication.please remove the extra e-mail in your free time. There are two servers ,the first installation of 32-bit linux(RHEL),the second installlation