only that the generations of the children of Israel might know, to teach them war, at the least such as before knew nothing thereof;
It was only that the generations of the Israelites might know and be taught war, at least those who previously knew nothing of it.
only that the generations of the children of Israel might know, to teach them war, at the least such as beforetime knew nothing thereof:
They survived only to teach war to the generations of Israelites who had no firsthand knowledge of the earlier wars:
so that afterward their sons might learn to contend with their enemies, and to have a willingness to do battle:
That afterwards their children might learn to fight with their enemies, and to be trained up to war.