HTTP methods- PUT, POST, GET and DELETE

Posted By: Matpal Media - 5:08 AM
HTTP methods are similar to CRUD (Create, Retrieve, Update and Delete) philosophy of DBMS. We can consider them in following terms. Suppose we consider Database as a resource (or our project) so following will be the meanings:

PUT: To create a new resource like a table. It creates a new resource if it’s not there and modifies if it’s already. (Like CREATE command of SQL).

POST: To update the resource. Like -to update the table adding a record in it. (Like INSERT or UPDATE command of SQL).

GET: To retrieve the data from the resource. Like - SELECT command of SQL.

DELETE: The DELETE method requests that the origin server delete the resource identified by the Request-URI. It’s like the DELETE command of SQL.

0 comments:

Post a Comment

Note: Only a member of this blog may post a comment.