-
Notifications
You must be signed in to change notification settings - Fork 185
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error while using sqlite database #82
Comments
I guess there is line number too in that error message that you missed to report? While you're at it can you please link to corresponding code line on GitHub? |
Actually tried modifying the Pdo.php as public function connect()
{
if ($this->config['dbtype'] == 'sqlite')
{
$connectionString = $this->config['dbtype'] .':'.$this->config['dbname'];
}
else
{
$connectionString = $this->config['dbtype'] . ':host=' . $this->config['dbhost'] . ';dbname=' . $this->config['dbname'];
} So that when the sqlite is required, there isn't necessity to provide the username and password. Also, the number that was linked was the return statement in the below snippet public static function getNextAssoc($resultSet)
{
return $resultSet->fetch();
} |
@Vidzz can you please use fenced blocks (see https://help.github.com/articles/github-flavored-markdown#syntax-highlighting) to enable code highlighting in your comments? |
I see you've made a fix, please submit it in PR (pull request) format. |
@Vidzz can you please send a PR with a fix? |
Encountered the following errors when used sqlite database.
I used the following configuration in the config:
$_xhprof['dbtype'] = 'sqlite:/path_to_folder/db_name';
$_xhprof['dbhost'] = '';
$_xhprof['dbuser'] = '';
$_xhprof['dbpass'] = '';
$_xhprof['dbname'] = 'db_name';
$_xhprof['dbadapter'] = 'Pdo';
There is no username and password for the sqlite.
The following error was returned:
Call to a member function fetch() on a non-object in xhprof_lib/utils/Db/Pdo.php
The text was updated successfully, but these errors were encountered: