One evening in a restaurant here in the capital of Kazakhstan, a Uighur and a Kazakh, members of two local Turkic nationalities, were discussing the issue of merging cultures.

The Uighur told of his niece who had married a Kazakh; their children spoke Kazakh. The Kazakh spoke of his sister's children who were brought up to speak the language of their father -- Korean.

The point, the two men noted, was that in these and other cases of local mixed marriages, the father passed on his native language to the children. As for the mother -- well, they said, she could always speak to her family in Russian, the language they could all understand.

With 100 different ethnic groupings, Kazakhstan -- the Soviet Union's second-largest republic, four times the size of Texas -- is also one of its most polyglot, and its population is still creating its own identity.

How Kazakhstan's ethnic kaleidoscope will shift during the next century is not clear. The situation here reflects to some extent the Soviet Union's broader "nationalities problem."

Experts here see a gradual rapprochement of nationalities as inevitable, but they also want to protect minority cultures and nations.

Kazakhstan is the only non-Russian Soviet republic where the official nationality was long ago outnumbered by Russians, who make up 40 percent of the population and form its largest ethnic group.

The republic's population in 1984 was 15.6 million, and at least 36 percent are Kazakhs, whose ancestors broke off from the Mongol Golden Horde in the 15th century. Moslem by religion, speaking a Turkic language, the Kazakhs ethnically have most in common with Mongolians.

Because of Kazakhstan's role in the "virgin lands" agricultural effort and other major development campaigns, the hand of Moscow has been felt keenly. The "big brother-little brother" model often cited to describe the Russian relations with other Soviet nationalities is all the more apparent here, but at the same time the region is more integrated.

The Russians' dominance here is beginning to be whittled down by the soaring Kazakh birthrate. The percentage of Kazakhs in Kazakhstan has climbed from 32.6 percent in 1970 to 36 percent in 1979. In another 20 years, Kazakhs are expected to outnumber Russians again.

"Kazakhs love children," commented the head of the republic's planning agency, a Kazakh. On a state farm where 26 percent of the workers were Kazakhs, the director noted that families with more than eight children were not uncommon.

But the Kazakh population may find it difficult to assert the kind of cultural dominance achieved by Georgians in Soviet Georgia, Armenians in Armenia or Uzbeks in Uzbekistan. The immense size of Kazakhstan, the roots put down by the non-Kazakh immigrants and the dispersal of the Kazakh population are likely obstacles.

Already, the percentage of Kazakhs claiming Kazakh as a first language, while still high at 97.5 percent, has declined slightly; this has not happened with the national languages in other Central Asian republics.

A more rapid erosion of language and culture is taking place among the ethnic Germans, who make up 6.1 percent of Kazakhstan's population. In 1926, only 5 percent of Soviet Germans claimed Russian as their mother tongue; by 1980, the number had risen to 43 percent.

Of the 3.9 million registered marriages, 20 percent are mixed, according to the republic's Academy of Sciences.

Authorities here point with pride to the institutions, theaters, newspapers and schools that sustain the identities of the main non-Russian cultures -- Kazakh, German, Uighur, Uzbek and Korean, an odd mix resulting from 100 years of migrations and "resettlements."

After the 1917 revolution, during the period of collectivization, the Kazakh population suffered severe losses. One estimate puts the number at 1 million people. But the losses were made up during and after World War II, when the Soviet government shipped suspect nationals -- Germans from the Volga and Koreans from Sakhalin Island -- to the empty expanses of Kazakhstan.

Today, there are 92,000 Koreans here and 800,000 Germans -- the largest concentration in the Soviet Union. Many of the republic's 148,000 Uighurs came from China, crossing the border in the 1960s.

In the 1950s, when Kazakhstan became the focus of the ambitious "virgin lands" campaign, its population soared with more arrivals from European Russia. The republic's coal mines, rich mineral deposits and growing industries also required imported labor.

The result is a population mix that to some extent is still creating its own identity. "I am a Kazakh," said a brown-haired, blue-eyed Russian foreman at a metallurgical factory in the coal center of Karaganda. "I was born here."

Kazakhstan's multilingual, multinational character is perhaps most apparent here in Alma-Ata, a city on the slopes of the Tien Shan Mountains filled with rose gardens, Lombardy poplars and a dozen varieties of black elms.

Because of the high risk of earthquakes, the city's skyline is low, spared the monotonous rows of high-rise apartment buildings typical of most Soviet cities. In the summer heat, the streets have a languid southern air; winters, however, can be fierce, with temperatures of -15 degrees Fahrenheit.

Local nationalities in the capital have meshed more than in the countryside, pushing Russian to the fore. A tourist guide, half-Russian and half-Kazakh, admitted during a conversation in the Alma-Ata market that her Kazakh was not as good as it should be. By way of explanation, she pointed to the variety of faces -- Uzbeks, Tajiks and nationalities from republics to the south -- behind counters loaded with fruits, vegetables and flowers. "There are so many different people here," she said, "and before the revolution, there were no institutions for the Kazakh language."

The 1917 revolution, as many here will point out, brought many changes, including literacy. "Thanks to the great Russian people and the Communist Party, we have made great improvements," said T. Mohammed-Rakhimov, head of the Kazakh Central Planning Agency and deputy prime minister.

But for many non-Russians, the move to Kazakhstan was not voluntary. The Volga Germans were deported here at the start of World War II from their autonomous republic in southern Russia that had been created in 1924. Although the current interpretation is that they were "transported" for their own protection, the wording of the 1941 decree said they were suspected of harboring "thousands and thousands of saboteurs and spies."

Soviet Germans regained their civil rights in 1955 and were fully rehabilitated by Nikita Khrushchev in 1964. But like the Crimean Tatars, another group deported as a result of the war, the Volga Germans never got back their lands.

Three decades ago, as part of improving Soviet relations with West Germany, Moscow began to give Soviet Germans permission to emigrate to reunite with relatives in West Germany. Germans have been in Russia for two centuries, first brought here by Catherine the Great, but once the gates opened, many applied to leave, citing among other problems the lack of a cohesive German community.

About 90,000 exit visas have been granted to Soviet Germans since 1955. But the flow peaked in 1976 at 9,626 and since then, as with Jewish emigration, the numbers have dropped sharply. Last year, only 864 received permission to go. Estimates of the number still waiting range from 80,000 upward.

Officials here insist that German culture is flourishing, and that it is getting the support it needs. They point to the daily newspaper, Freundschaft, published in Tselinograd, with a 50,000 circulation, the German theater in Temirtay, a weekly television program and a daily radio program in German.

They see the subject of emigration as an attack on the Soviet states. Speaking to foreign journalists, Leo Weidman, editor of Freundschaft, attacked West Germany for trying to lure Soviet citizens away with money. "Why do you need our people?" he asked in Russian, answering a question put by a West German journalist. "It's a conspiracy against the Soviet Union."

But there is evidence that language and culture are losing their hold in some places. At the central Kazakhstan state farm of Erkenshilikski, with a population that is 51 percent German, people with German surnames were reluctant to use the language.

The farm's chief, Andrei Andreivich Rimmer, a burly man with a bellow that needs no translating, is a Soviet German whose best language is Kazakh, or at least so say some colleagues. Rimmer demurs.

"I don't speak pure German, I don't speak Russian and I don't speak pure Kazakh," he said, "but I make myself understood."