Hello,

I am trying to write pdf and word files from disk to database and extract these files again to disk. Al seems to be going fine, but the extracted file is 1 kb and should be 22 kb (the original file size). Using Read_Block to read the document, but it only reads 220 characters if I read it into a Uchar[]. After extracting the information from the database and saving it to disk using Direct_output ('Binary:'+sFilename) and then writing the database data using the write command to disk results in the 1 kb unreadable file.

Is there a example to be found somewhere that shows me how to do this?

Using:
DataFlex 19.0, SQL Server 2017

Regards,

Leon Raafs