The AWACS controversy has left the United States with a "commitment" to Saudi Arabia of just the sort that critics of the war wished we had had in Vietnam.

The never-again impulse of that period flowered, Sen. Charles McC. Mathias Jr. (R-Md.) observed not long ago, in the Senate's national commitments resolution of 1968. It precluded the United States from entering into a binding commitment to another country except by "treaty, statute or joint resolution."

Some have seen this resolution as a dated relic of another day's mortification, a paper key tardily locking a horseless barn. Mathias believes, however, entirely correctly, that the resolution expresses a continuing wisdom that the country ignores at its peril.

In recent years the country had ignored it in respect to Saudi Arabia. This was doubly troubling. Saudi Arabia is a country of growing importance to us and our allies on account of its oil and the forms of power arising from oil. It is also, on account of its ruling family's political vulnerability to internal pressures and the country's physical vulnerability to outside pressures, a risky place to invest American fortunes.

Nonetheless, Jimmy Carter, who was elected promising to apply just such "lessons" of Vietnam as the commitments resolution, lost his bearings after the Soviets invaded Afghanistan. Without so much as a tip of the hat to Congress, which itself was supine, he committed the United States to the defense of the Persian Gulf, meaning principally the Saudis, against an "outside force." He then dispatched American AWACS planes. These are natural first targets, and sending them ensured that we would be involved in any attack on Saudi Arabia from the start.

Ronald Reagan expanded this commitment, declaring that the United States would also aid the Saudi royal family in certain circumstances of internal unrest. His extraordinary pronouncement amounted to the dropping of a second shoe: if Saudi oil is "vital" to us, its flow must be ensured by whatever means necessary, whether the threat arises outside the country or inside.

The Carter and Reagan commitments unfolded almost entirely in the absence of formal or comprehensive congressional review.

This was the situation up to the point last month when Mathias, observing that the AWACS sale would amount to a national commitment "as important as any treaty we have entered into in recent years," warned the Senate that "national commitments should not be the result of unintended incremental entanglements."

What finally came about was an exceptionally thorough and searching inquiry into the nature of the evolving U.S.-Saudi relationship and into the effects of the sale and non-sale of AWACS on our diverse interests in the Middle East: into, in brief, a "commitment."

The Saudis, secretive desert recluses that they are, must have squirmed as they watched the Senate and all the others who participate in our raucous political debate ransacking Saudi closets, so to speak, holding up every national failing and weakness for public viewing like so many quaint old family photographs.

Yet there is a logic to the process of passionate congressional review. It can be a punch in the gut even to Americans inured to it. But it is a splendid way to sort through a complex issue and to give all those who wish to participate in decision-making the chance to do so. Any country that would wish to enter into a close tie with us had better realize that such a review is unavoidable. The Israelis, who have our kind of messy open society, are used to it. The Saudis, who don't, have to learn.

That said, it becomes essential to look carefully at what the Senate has wrought. Suppose your betrothed had said that he or she had decided to marry you--by a vote of 52 to 48. The narrow margin of Reagan's victory, the evident ambivalence felt by so many of those who supported him and the variety of grounds on which they voted underline the tentative and conditional nature of the Senate's verdict. Clearly, many senators have doubts about the Saudi commitment, or at least about the president's way of managing it.

Reagan has a formal mandate to proceed with the AWACS package, but he has a practical need to stay within the limits of the Senate's reservations. The Senate has made the American connection to Saudi Arabia a national commitment, not merely a presidential one. The president will do best by respecting the cautions indicated by that broader frame.