You are viewing a single comment's thread from:

RE: [STEEMSQL] A public SQL database with all blockchain data – UPDATE 1

in #steemit9 years ago

Thanks for your comment.
It's quite easy to connect using PHP :


<?php
$serverName = "sql.steemsql.com";
$connectionInfo = array( "Database"=>"DBSteem", "UID"=>"steemit", "PWD"=>"steemit");
$conn = sqlsrv_connect( $serverName, $connectionInfo);

if( $conn ) {
     echo "Connection established.<br />";
}else{
     echo "Connection could not be established.<br />";
     die( print_r( sqlsrv_errors(), true));
}
?>

Sort:  

By default, on my mac, PHP doesn't come compiled with the drivers needed so you end up with this:

Fatal error: Call to undefined function sqlsrv_connect()

I spent a long time this past weekend at the RESTfest hackathon trying to get the PDO stuff to work on my mac. It turned into a big pain, unfortunately.

Are you running PHP on windows, already compiled with php_sqlsrv_53_ts.dll? If you could get this working on OSX, that would be fantastic.

Unfortunately not working on OSX. Contact me on SteemSQL channel and we will see if we can solve it.

Coin Marketplace

STEEM 0.05
TRX 0.29
JST 0.043
BTC 67695.24
ETH 1968.96
USDT 1.00
SBD 0.38