The numbers are sobering. The federal government reported Tuesday that immigration agents apprehended 76,000 people — most of them families or unaccompanied minors — at the U.S.-Mexico border in February, twice the level of the previous year and the highest for February in 11 years. The increase continues a trend that began in the fall, and offers direct evidence that President Trump’s strategy of maximal enforcement at the border is not reducing the flow of migrants.

And no, the answer is not “a big, beautiful wall.” Most of those apprehended weren’t trying to sneak past border agents; instead, they sought out agents once they reached the border and turned themselves in, hoping to receive permission to stay.

Furthermore, the situation isn’t a national security emergency, as he has declared in an effort to spend more on his border wall than Congress provided. It’s a complex humanitarian crisis that appears to be worsening, and it’s going to take creative analytical minds to address.

For instance, the vast majority of the families flowing north in recent months come from poor regions of Guatemala, where food insecurity and local conflicts over land rights and environmental protections are pushing more people off their farms and into even deeper poverty, according to human rights observers and U.S. Customs and Border Protection. Just months earlier, gang violence in urbanized areas were pushing people north to the United States; increasingly now, it’s economics.

But Trump’s rhetoric may be playing a role too. The more he threatens draconian enforcement and cutbacks in legal immigration, the more people contemplating moving north are pushed to go sooner, before it gets even harder to reach the U.S. Similarly, more migrants are arriving at more treacherous and remote stretches of the border to avoid getting stuck in Tijuana or other border cities where the U.S. government has reduced the number of asylum seekers it will allow in, claiming an inability to process the requests.

The system is overwhelmed. But the solution isn’t to build a wall, incarcerate more people, separate children from their parents or deny people their legal right to seek asylum. The solution is to improve the efficiency and capacity of the system to deal with the changed migrant demographics. A decade ago, about 1 in 100 border crossers was an unaccompanied minor or asylum seeker; now about a third are.

More judges and support staffs are necessary for the immigration court system, as the Trump administration has sought from Congress. Yet the case backlog there has continued to grow — in part because the increase in enforcement actions, in part because the Justice Department ordered the courts to reopen cases that had been closed administratively without deportations, often because the migrant was in the process of obtaining a visa. A faster and fair process would give those deserving asylum the answer they need sooner, cutting back on the years they spend in limbo, while no longer incentivizing those unqualified for asylum to try anyway.

The Migration Policy Institute, a think tank, has suggested one partial fix. Currently, migrants claiming asylum have a near-immediate initial “credible fear” hearing with an asylum officer from U.S. Citizenship and Immigration Services, who determines whether the migrant has a significant potential to make a successful asylum claim. Most migrants pass that low threshold and are then directed to the immigration courts to make the formal case, a more involved process that can take years. Keeping those cases within the citizenship and immigration branch for an administrative hearing instead of sending them to immigration court could lead to faster decisions for the deserving at a lower cost — a single asylum agent is cheaper than a court staff — while preserving legal rights by giving those denied asylum a chance to appeal to the immigration courts. That’s a process worth contemplating.

More fundamentally, the current system hasn’t worked for years, and under Trump’s enforcement strategy it has gotten worse. It’s a big ask, but Congress and the president need to work together to develop a more capable system that manages the many different aspects of immigration in the best interests of the nation while accommodating the rights of the persecuted to seek asylum.