0

Have a table with an id and a clob field in database. Need is to implement a Post service to persist data for this table for which an entity is designed with @lob for (CLOB column String java type) and @id(ID) in db. I have designed a rest service which takes input in the format below- { id: input_id, data: clob_data }

How do we pass id and the contents of the file to get stored via rest and curl. Or if there is a better way to implement open for suggestions.

1 Answer 1

1

You could move the ID from the POST body to the URL. This would allow the POST body to just be the file content which would then allow a simple curl command like this:

curl -d @file_to_post https://<your_server>/path/to/service/<input_id>
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.