views:

40

answers:

1

I have the following command which works fine on Linux Console. But to get the result to a cpp file I have to store it to file and then read it. But is there a way I can directly execute this command in C++.

/usr/bin/sqlite3 /etc/myDB/db/share.db "select path from folder_info where ftp='YES'"
+3  A: 

As far as i understand your question you can use the SQLite3 c++ api which is described here

lexa78
You can also check this demo project (it`s for windows, but it will get the overall idea) - http://www.codeproject.com/KB/database/CppSQLite.aspx
lexa78
You can also use the C API into sqlite from C++.
MarkR