我已经从https://github.com/orientechnologies/PhpOrient安装了OrientDb PHP官方驱动程序.
现在,在PHP页面中,我只希望它使用print_r()函数仅显示'user'集合的属性值,例如user_id,username,email_id,mobile等.
$client = new PhpOrient( 'localhost', 2424); $client->username = 'root';
显示输出的代码如下::
$client->password = 'root'; $client->connect(); $ClusterMap = $client->dbOpen( 'krshop', 'root', 'root' ); $data = $client->query( 'select from user limit 10' ); echo "";print_r($data);使用orientdb的php的用户集合数据
1> 小智..:试试这段代码:
$client = new OrientDB('localhost', 2424); $client->connect('root', 'root'); $client->DBOpen('krshop', 'root', 'root'); $data = $client->select('select from user limit 10');