Skip to content
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

sim: add sqlite configuration #12305

Merged
merged 1 commit into from
May 17, 2024
Merged

sim: add sqlite configuration #12305

merged 1 commit into from
May 17, 2024

Conversation

Gary-Hobson
Copy link
Contributor

Summary

Add sqlite based on sim/minibasic configuration

Impact

Since hostfs does not support FIOC_FILEPATH, it cannot currently be used in hostfs

Testing

nsh> cd tmp
nsh> ls
/tmp:

nsh> sqlite3 test.db
SQLite version 3.45.1 2024-01-30 16:01:20
Enter ".help" for usage hints.
sqlite> 

 CREATE TABLE COMPANY(
   ID INT PRIMARY KEY     sqlite> (x1...> NOT NULL,
   NAME           TEXT    NOT NULL,
   AGE            (x1...> (x1...> INT     NOT NULL,
   ADDRESS        CHAR(50),
   SALARY         (x1...> (x1...> REAL
);(x1...> 

sqlite> .schema COMPANY
CREATE TABLE COMPANY(
   ID INT PRIMARY KEY     NOT NULL,
   NAME           TEXT    NOT NULL,
   AGE            INT     NOT NULL,
   ADDRESS        CHAR(50),
   SALARY         REAL
);
sqlite> .quit
sqlite> 
nsh> 
nsh> ls -l
/tmp:
 -rwxrwxrwx       12288 test.db

Copy link
Contributor

@acassis acassis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please include the Summary/Testing execution example at board "Configurations" as sqlite entry here: https://nuttx.apache.org/docs/latest/platforms/sim/sim/boards/sim/index.html

@acassis
Copy link
Contributor

acassis commented May 15, 2024

ping @Gary-Hobson

@Gary-Hobson
Copy link
Contributor Author

ping @Gary-Hobson

Documentation has been added, but this PR still needs to wait for #12303 to be merged, but it also depends on 2396
Documentation has been added, but this PR still needs to wait for fff to be merged, however it still depends on apache/nuttx-apps#2396

If there are no other problems with CI, it can be merged tomorrow.

Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
@acassis acassis merged commit e6ed8c6 into apache:master May 17, 2024
7 of 26 checks passed
@xiaoxiang781216
Copy link
Contributor

Impact

Since hostfs does not support FIOC_FILEPATH, it cannot currently be used in hostfs

Please upstream the patch which make hostfs support FIOC_FILEPATH.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants