SQLite Forum

Special characters * and ? are not supported in Database Names on Windows?
Login
Hi, 
I am able to create database name with special characters including * and ? on RHEL 8, Sqlite3. But it fails on windows Server 2016. 

So, how do I do this in windows, it works fine in RHEL 8.

Following fails on windows 2016:
==============================

~~~
C:/user1/db>sqlite3 'Test*DB2'
SQLite version 3.35.5 2021-04-19 18:32:05
Enter ".help" for usage hints.
sqlite> create table IF NOT EXISTS table1 (field1 varchar(10));
Error: unable to open database "'Test*DB2'": unable to open database file

C:/user1/db>sqlite3 'Test\*DB2'
SQLite version 3.35.5 2021-04-19 18:32:05
Enter ".help" for usage hints.
sqlite> create table IF NOT EXISTS table1 (field1 varchar(10));
Error: unable to open database "'Test\*DB2'": unable to open database file
~~~

But passes in RHEL 8.
=====================

~~~
# sqlite3 'Test*DB4'
SQLite version 3.35.4 2021-04-02 15:20:15
Enter ".help" for usage hints.
sqlite> create table IF NOT EXISTS table1 (field1 varchar(10));

sqlite># ls -l
-rw-r--r--. 1 root root  8192 May 14 16:10 'Test*DB4'
~~~

Thanks,
Narendra