Arduino Client not able to Insert Data to a Cloud Server Instance

I am not clear exactly which parts are working and which ones are broken, but it seems to me that currently you are trying to get the whole solution to succeed. This 'big bang' approach is the hardest way to tackle problems like this. I suggest you break the problem down.

Take the Arduino out of the equation first, and use a plain old web browser to send your HTTP requests.

Remove all the database code from the PHP servlet and confirm that you can successfully send a request to it and get back a response.

Then add code to the servlet to extract your request parameters from the URL and echo them back to the client, and confirm that works.

Then add code to the servlet to open and close a connection to the database and confirm that works.

Then add code to execute an innocuous hard-coded query such as select count(*) from a table you expect to exist and be accessible to you, and confirm it succeeds.

Then add code to print out your SQL query string.

Then change that to execute your query and confirm it succeeds.

Then code your Arduino sketch to submit the same HTTP request and confirm it produces the same behaviour.