You have to first understand and internalize the idea that hex notation is only an easy-to-read representation of binary. You don't have to, and must not, write any such conversion program. But firstly I have to write a program, that will convert this file to hex file.' You said: 'I' d like to upload file on server, for example pdf file. I still claim the exercise is a complete waste of time,since blobs can contain binary data: that's what blobs were invented for. He wants to convert his pdf file to its hex representation, as I see now, because he wants to put that file in a text blob field in some database table. After that, I will upload this file line by line with PL/SQL.ĮDIT: I completely misunderstood what the OP was aiming for. I'd like that the length of a line in hex file would be equal 1024. But firstly I have to write a program, that will convert this file to a hex file.
I' d like to upload a file on server, for example a PDF file. After invoking this code I have still strange characters in my file_test file. N = fread(buffer, 1, bufferSize, source) I have written something, but it does not work properly. I' d like to convert binary files to hex. I am trying to write some simple program to uploading files to my server.