Hi Marc,
> Using dbase I succeeded in writing othe train to ut a doc this way, for
> mysql or hsql the office hangs. See some code below, maybe the
> limit-argument is the problem, which I set to 65536 as a limit and the
> document was anytime smaller than that on storage (~30kB).
it might ... The length argument is used for XInputStream.readBytes (in
some cases, for XInputStream.readSomeBytes, which I consider a bug), and
though the API definition says the method should return in case of EOF,
there might be a bug somewhere that it blocks in this case.
> <code>
> ...
> sql = "INSERT INTO ""pieces"" (""ID"", ""piece"") VALUES (?, ?)"
> oPStatement = aConnection.prepareStatement( sql )
> oPStatement.setInt(1, aID)
>
> dim Args(0) as new com.sun.star.beans.PropertyValue
>
> oPipe = CreateUNOService("com.sun.star.io.Pipe")
> Args(0).Name = "OutputStream"
> Args(0).Value = oPipe ' s.u.
>
> ' order IS IMPORTANT !!! for dbase ...
> tmpDoc.storeToUrl("private:stream", Args())
>
> ' never-come-back-call ...
> oPStatement.setBinaryStream(2, oPipe, 65536)
>
> oPStatement.executeUpdate()
>
> </code>
Will try to reproduce. As always, an issue is highly welcome, and might
speed up things :)
Thanks & Ciao
Frank
--
- Frank Schönheit, Software Engineer [EMAIL PROTECTED] -
- Sun Microsystems http://www.sun.com/staroffice -
- OpenOffice.org Base http://dba.openoffice.org -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]