Can we create a full fledged CRUD application(login form) in Rust?

...

I have specified DELETE url, but GET is performed with an error

ganeshkodaganti,

Do you have a "route attribute" for DELETE on your delete function, as per the Rocket documentation: Requests - Rocket Programming Guide

You need something like:

#[delete("people/delete/<id>")]
fn delete(id: i32, conn: DbConn) -> Result<Flash<Redirect>, Template> {
    ....
}

Have you added the route to the routes vector on start up, like so:

fn main() {
    rocket::ignite().mount("/", routes![index, delete]).launch();
}

I suggest you work through the examples in the documentation to get a clear understanding of what goes on in Rocket.

Yes, I have added the route

I'm asking again, how do you generate the HTML? If this is not performed by some frontend Rust framework, this look like a question "how do I send the non-GET request from webpage?", which is irrelevant to Rust (and in this case just google "fetch API", to start with something).

I have just downloaded and ran the code. Check out this link Creating a REST API in Rust Using Rocket and Diesel - DZone Integration.

There is no use of HTML or any front end framework in the link.

If there's no use of HTML, then how do you send the GET requests? I can't read through the link for now, it should be a lot easier for you, since you've already followed the steps being described.

When I enter the URL the below screen appears.
Screenshot%20from%202019-09-26%2013-48-47 ...

Your 404 not found error is for a GET request.

But I guess you have defined a DELETE route. Perhaps like so:

#[delete("people/delete/<id>")]
fn delete(id: i32, conn: DbConn) -> Result<Flash<Redirect>, Template> {
    ....
}

Clearly that will not work. You need to make DELETE requests on it.

OK, so you're simply sending them from the browser. If you want to simply test the queries (without the UI), just start with something like Postman. If you want to send them from the browser (using some kind of form), check Rocket templates and aforementioned Fetch API.

#[delete("/delete/<id>")]
pub fn delete(id: i32, connection: DbConn) -> Result<Status, Status> {
    match people::repository::get(id, &connection) {
        Ok(_) => people::repository::delete(id, &connection)
            .map(|_| Status::NoContent)
            .map_err(|error| error_status(error)),
        Err(error) => Err(error_status(error))
    }

The error you showed says it is trying to reach "/people/delete"

That code above is on route "/delete"

Are you catering for the leading "/people" somewhere?

Edit: OK Ignore this. It's answered below.

rocket::ignite()
        .manage(connection::init_pool())
        .mount("/people",
               routes![people::handler::all,
                    people::handler::get,
                    people::handler::post,
                    people::handler::put,
                    people::handler::delete],
        ).launch();
rocket::ignite()
        .manage(connection::init_pool())
        .mount("/people",
               routes![people::handler::all,
                    people::handler::get,
                    people::handler::post,
                    people::handler::put,
                    people::handler::delete],
        ).launch();

I have mentioned to mount at /people

@ganeshkodaganti, please note this. Does it answer youer question, or you've checked the suggestions and can describe why they aren't giving you what you want?

My doubt is , when I have entered the DELETE method URL it isn't being performed.Can you help me??

When the URL is typed into address bar, the browser ALWAYS sends the GET request. Not POST, PUT or DELETE, or something. All other kinds of requests must be sent either from HTML form (by setting the button action), or from JavaScript, or through some other application, like the mentioned Postman. Does this make sense?

Yes..