Hi Christian, R provides a package which makes it rather easy to use C++ code. That is why I focused on C++. I first tried to understand the BaseXCPPAPI as provided by Jean-Marc Mercier but for a complete novice on C++, that code was way too complicated for an old man like me (I'm retiring TODAY ;-)). The C-code from Alexander Holupirek is much easier to understand and for the moment I'm trying to convert his code to a C++-variant that can be both used by my RbaseX and a new C++-client.
Usually, I first experiment in the GUI to learn which statements I have to use for a query. After that I use the same statements in my client. I noticed that often execution in the GUI only took miliseconds while execution in the client could take minutes (depending on the size of the input or the results). It is my guess that this boiles down to read/write operations on the connection. In R, I have isolated all actions upon the stream into one R-class. And my first goal is to create a C++ class that is functionally equivalent. Hopefully that will improve performance. If I manage in that, I am halfways into building a C++ client that offers the same functionality as my RbaseX-client. Who knows If I'll succeed in that ;-) . Cheers, Ben Op 30-06-2020 om 11:56 schreef Christian Grün: > Hi Ben, > > The BaseX server protocol was specified without focus on any > particular programming language. > > If there is no way to speed up stream processing with R, you could > have a look at the existing C++ client implementation . Maybe > you’ve done so already? > > Cheers, > Christian > >  https://docs.basex.org/wiki/Clients