Return-Path: Delivered-To: apmail-lucene-hadoop-commits-archive@locus.apache.org Received: (qmail 90715 invoked from network); 15 Nov 2007 13:26:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 15 Nov 2007 13:26:17 -0000 Received: (qmail 88927 invoked by uid 500); 15 Nov 2007 13:26:04 -0000 Delivered-To: apmail-lucene-hadoop-commits-archive@lucene.apache.org Received: (qmail 88906 invoked by uid 500); 15 Nov 2007 13:26:04 -0000 Mailing-List: contact hadoop-commits-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hadoop-dev@lucene.apache.org Delivered-To: mailing list hadoop-commits@lucene.apache.org Received: (qmail 88897 invoked by uid 99); 15 Nov 2007 13:26:04 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 15 Nov 2007 05:26:04 -0800 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.130] (HELO eos.apache.org) (140.211.11.130) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 15 Nov 2007 13:26:02 +0000 Received: from eos.apache.org (localhost [127.0.0.1]) by eos.apache.org (Postfix) with ESMTP id 39495D2DD for ; Thu, 15 Nov 2007 13:25:56 +0000 (GMT) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Apache Wiki To: hadoop-commits@lucene.apache.org Date: Thu, 15 Nov 2007 13:25:56 -0000 Message-ID: <20071115132556.21186.27158@eos.apache.org> Subject: [Lucene-hadoop Wiki] Trivial Update of "Hbase/HbaseShell/PHP" by udanax X-Virus-Checked: Checked by ClamAV on apache.org Dear Wiki user, You have subscribed to a wiki page or wiki category on "Lucene-hadoop Wiki" for change notification. The following page has been changed by udanax: http://wiki.apache.org/lucene-hadoop/Hbase/HbaseShell/PHP ------------------------------------------------------------------------------ === How to connect to HShell/HQL Server database === Below is the code for connecting to a HShell/HQL Server database. - {{{ + {{{#!java - include_once("HShellConnect.class.php"); + include_once("HShellConnect.class.php"); //create an instance of the HShell connection object $hbase = new HShellConnect("Host_Address", Port_Number); - //execute the HQL statement and return records $result = $hbase-> executeQuery("queryString"); - if($result) { + if($result) { print "Rows Count: ".$result->getRowCount()); //carry on looping through while there are records while($tuple = $result->getNext()) { - foreach($tuple as $columnName => $cellValue) { print "Column Name: ".$columnName; print "Cell Value: ".$cellValue; } - } } }}}