* Saudi retail sector firms
* United Electronics down on profit-taking
* Foreign funds net buyers in Qatar
* Egypt holds at record high
By Celine Aswad
DUBAI, July 12 (Reuters) - Stock markets in the Middle East rose on Wednesday, bolstered by banking shares ahead of testimony from Federal Reserve Chair Janet Yellen that could offer clues on when the central bank will tighten U.S. monetary policy.
Most Gulf currencies are pegged to the dollar and any monetary policy change in the United States is usually mimicked by Saudi Arabia, the United Arab Emirates and Qatar.
In Saudi Arabia all 12 of the listed lenders advanced, half of them rising by 1 percent or more, helping to push the index 0.8 percent higher.
Consumer-related shares also firmed on expectations of improving performance from the sector in the second quarter.
Analysts at NCB Capital expect the government's decision to reinstate civil servants' allowances to lift average monthly household expenditure back to 11,523 riyals ($3,072.80), with discretionary spending growing by a quarter to 3,578 riyals.
On June 20 the government said it will reinstate the public sector workers' allowance that had been cut in October 2016 because of pressure on state finances.
Analysts said the food sector is likely to account for the biggest chunk of total spending but that they expect accelerating demand for home appliances.
Shares in supermarket company Al Othaim -- NCB Capital's top pick in the consumer sector -- jumped 3.1 percent on Wednesday.
United Electronics, meanwhile, gave up earlier gains, with its shares falling 1.8 percent on profit-taking. They remain 17 percent up since Monday, when it announced a surge in net profit, the board's recommendation to distribute its first cash dividend since 2015 and future product and online expansion plans.
In Qatar, foreign traders made up a nearly a third of the total market turnover and they were net buyers by a modest margin, helping to boost the price of some of their favoured stocks. Lender Masraf Al Rayan climbed 4.4 percent.
Forty other companies advanced and only one declined as the index jumped by 2.8 percent.
The benchmark has now risen by 2.7 percent since the start of July but is down 6.5 percent since June 5, when Saudi Arabia and three other Arab states severed diplomatic and trade links with Doha.
In the United Arab Emirates, Dubai's index gained 1.6 percent on the back of a 10.7 percent surge in shares of developer DAMAC Properties. Abu Dhabi's index was flat.
Cairo's largest listed lender, Commercial International Bank , added 0.8 percent. The index finished flat, holding at a record closing high.
* The index added 0.1 percent to 7,245 points.
* The index added 1.6 percent to 3,494 points.
* The index inched up 0.02 percent to 4,410 points.
* The index gained 2.8 percent to 9,280 points.
* The index climbed 1.5 percent to 13,684 points.
* The index added 0.2 percent to 6,795 points.
* The index rose 0.4 percent to 1,317 points.
* The index flat at 5,170 points. ($1 = 17.8700 Egyptian pounds) ($1 = 3.7501 riyals) ($1 = 17.8300 Egyptian pounds) ($1 = 3.7500 riyals) (Editing by David Goodman)