The problem you are referring to means that several things were skipped, hence the resulting system went wrong. Let me describe some of the missing steps:
Quality Management - Do it right the first time! Never use any temporary hacks, or temporary compromises. There shall be no rework needed. All resources are used efficiently and everything you do is a proper contribution to the project.
Feasibility Analysis - Discover business need. Create a business case for the project.
Project Plan - Clearly define your initial scope, plan how the solution will be delivered, create a baseline, stick to the plan. Don't spend time on anything that's not on the critical path.
Requirements Engineering - Elicit business requirements (i.e. capture business processes and determine what business operations should be supported by the computerized system, translate 1:1 business operations to system use cases). Validate & verify! (are we building the right thing? Are we building the thing right?) All requirements must be linked to the original business need.
Software Design - Translate use cases and domain model into component design and solution architecture. All components must be linked to the requirements from RE.
Implementation - Code the software as in the design. All code must be linked to components from SD.
Validation - Unit testing, integration testing, performance, ... (all use cases from RE will now need to be tested)
These are some key aspects of a software process. Mentioned activities are part of Software Engineering. This is how you build the right software solution for the real business need, and you build it on time, on budget, to specification.
Look up these terms to build better software and to get it right the first time:
- Feasibility Analysis (esp. how to build a Business Case)
- Project Management (esp. Project Plan and Risk Register with Risk Mitigation)
- Requirements Engineering (elicitation, analysis, specification, validation)
- Software Design (UML and component-based software engineering)
- Software Construction (design patterns, frameworks, defensive programming)
- Software Validation (unit testing, UAT, etc.)