vfs question: how to pass binary/blob arg to xCreate()?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

vfs question: how to pass binary/blob arg to xCreate()?

Liam Staskawicz
Hi,

I'm just getting started exploring the vfs capabilities of sqlite, and
am interested in providing a binary blob argument  to xCreate(), as that
blob  includes a schema description used to generate the CREATE TABLE
statement. The existing argument interface is string based, so I'm
wondering if there's a way to avoid doing something like base64 encoding
the blob as a string, or something along those lines.
Thanks for any tips.

Liam
_______________________________________________
sqlite-users mailing list
[hidden email]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: vfs question: how to pass binary/blob arg to xCreate()?

Richard Hipp-3
On 10/20/17, Liam Staskawicz <[hidden email]> wrote:
> Hi,
>
> I'm just getting started exploring the vfs capabilities of sqlite, and
> am interested in providing a binary blob argument  to xCreate(),

No.  The arguments to xCreate() are copies of the arguments to the
CREATE VIRTUAL TABLE statement that creates the virtual table, and the
SQL language is written in text, so the arguments to xCreate must also
be text.
--
D. Richard Hipp
[hidden email]
_______________________________________________
sqlite-users mailing list
[hidden email]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|

Re: vfs question: how to pass binary/blob arg to xCreate()?

Darko Volaric
In reply to this post by Liam Staskawicz
You could try Unicode binary encoding to increase the efficiency when passing binary as strings: https://qntm.org/unicodings <https://qntm.org/unicodings>


> On Oct 20, 2017, at 7:20 PM, Liam Staskawicz <[hidden email]> wrote:
>
> Hi,
>
> I'm just getting started exploring the vfs capabilities of sqlite, and
> am interested in providing a binary blob argument  to xCreate(), as that
> blob  includes a schema description used to generate the CREATE TABLE
> statement. The existing argument interface is string based, so I'm
> wondering if there's a way to avoid doing something like base64 encoding
> the blob as a string, or something along those lines.
> Thanks for any tips.
>
> Liam
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

_______________________________________________
sqlite-users mailing list
[hidden email]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users