php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #74184 Sqlite PDO doesn't support URI filenames
Submitted: 2017-02-28 18:05 UTC Modified: 2021-03-15 16:39 UTC
Votes:3
Avg. Score:5.0 ± 0.0
Reproduced:3 of 3 (100.0%)
Same Version:0 (0.0%)
Same OS:1 (33.3%)
From: sergey dot payu at gmail dot com Assigned: cmb (profile)
Status: Closed Package: PDO SQLite
PHP Version: master-Git-2017-02-28 (Git) OS: Any
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: sergey dot payu at gmail dot com
New email:
PHP Version: OS:

 

 [2017-02-28 18:05 UTC] sergey dot payu at gmail dot com
Description:
------------
Current implementation of Sqlite PDO does support ":memory:", but lacks support of "file:" scheme (URI filenames). This may be essential if one wants to change VFS. Trying to use URI filenames leads to "unable to open database" error. More information on URI filename can be found on official sqlite site: https://www.sqlite.org/c3ref/open.html#urifilenameexamples

Test script:
---------------
$pdo = new PDO("sqlite:file:/opt/databases/mydb.sq2?vfs=unix-ecl"); 


Patches

sqlite_driver.c.path (last revision 2017-02-28 18:05 UTC by sergey dot payu at gmail dot com)

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2021-03-15 16:39 UTC] cmb@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: cmb
 [2021-03-15 16:39 UTC] cmb@php.net
This has recently been implemented[1], and will be available as of
PHP 8.1.0.

[1] <https://github.com/php/php-src/commit/a8dd009f23ab9ccd6b63f58a203d49fd0513a50d>
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sun Apr 11 19:01:24 2021 UTC