Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6376933
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T01:48:24+00:00 2026-05-25T01:48:24+00:00

I have the following controller mapped as @Controller( value = stockToStoreController ) @RequestMapping(/stsr) public

  • 0

I have the following controller mapped as

@Controller( value = "stockToStoreController" )
@RequestMapping("/stsr")
public class StockToStoreController extends BaseController {...}

I have a delete mapping

@Transactional(propagation = Propagation.REQUIRED)
@RequestMapping(value = "/delete")
public String delete(@RequestParam("xxxId") long xxxId) {

    XXXModel xxxModel = stockToStoreDao.findById(xxxId);
    if(xxxModel != null) {
        xxxDao.delete(xxxModel);
    }
    return "/stsr/requery";
}

That mapping looks like this

@SuppressWarnings("unchecked")
@RequestMapping(value = "/requery")
public ModelAndView requery(HttpServletRequest request) {
    ModelAndView mav = new ModelAndView("manageStockToStore");

     //do stuff

     return mav;
}

I try to call another mapping in the return ie., return “/stsr/requery”; I get
the following error:

Uncaught exception thrown in one of the service methods of the servlet: mptstp. Exception thrown : javax.servlet.ServletException: Could not resolve view with name ‘/stsr/requery’ in servlet with name ‘xxx’

Question is, do I need to explicitly define this mapping somewhere? I do not have any MappingHandlers defined and my -servlet.xml looks like

    <!-- Configures the @Configuration annotation for java configuration -->
<context:annotation-config/>

<!-- Scans the classpath of this application for @Components to deploy as beans -->
<context:component-scan base-package="xxx.testspringmvc.stsr" />

<!-- Configures the @Controller programming model -->
<mvc:annotation-driven />

<!-- Configures resources so they can be used across web modules -->
<mvc:resources mapping="/resources/**" location="/, classpath:/META-INF/public-resources/" />

<!-- Application Message Bundle -->
<bean id="messageSource" class="org.springframework.context.support.ReloadableResourceBundleMessageSource">
    <property name="basenames" value="classpath:META-INF/public-resources/mptstp-messages, classpath:META-INF/public-resources/mptstp-error-messages, classpath:META-INF/public-resources/stsr/stsr-messages" />
    <property name="cacheSeconds" value="0" />
</bean>

<!-- Spring MVC View Resolver -->
<bean id="viewResolver" class="org.springframework.web.servlet.view.ResourceBundleViewResolver">
    <property name="basename" value="stsr-views" />
    <property name="defaultParentView" value="parentView"/>
</bean>

<mvc:interceptors>
    <mvc:interceptor>
        <mvc:mapping path="/**"/>
        <bean id="urlConfiguredSiteIdInterceptor" class="xxx.testspringmvc.stsr.interceptor.UrlConfiguredSiteIdInterceptor">
            <property name="siteIdConfigParamName" value="urlConfiguredSiteId" />
            <property name="errorView" value="siteIdNotFound" />
        </bean>
    </mvc:interceptor>
</mvc:interceptors>

Any help from you guys would be greatly appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T01:48:25+00:00Added an answer on May 25, 2026 at 1:48 am

    Two options:

    • you can redirect return "redirect:/stsr/requery"
    • you can directly invoke the other method: return requery(request);
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following controller @Controller @RequestMapping(/project/view.html) public class ProjectViewController { private static final
I have the following controller: class FooController : Controller { public ActionResult SomeAction(id) {
I Have following code: Controller: public ActionResult Step1() { return View(); } [AcceptVerbs(HttpVerbs.Post)] public
I have the following controller: public ActionResult Search(string Name, int? Friend, int? Page) It
I have the following code in my controller: public ActionResult Details(int id) { var
Hey - I have the following method on my UITableView controller public void RemoveEventFromList(Event
Suppose you have the following controller action [HttpPost] public ActionResult Save( CustomerModel model )
If I have the following controller action... public void DoSomething() { } will the
I have the following controller action: public ActionResult Edit(int id) { var news =
On ASP.NET MVC 3, assume that we have following controller action: public ActionResult Index()

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.