Glasgow has experienced a 17% drop in school meal uptake since healthy eating initiatives were introduced, MSPs have heard.
Healthier meals are being provided in schools
The figure was revealed at a Holyrood finance committee.
Glasgow City Council official, Fergus Chambers, said political decisions to ban unhealthy foods could eventually destroy the school meals service.
MSPs also heard that North Lanarkshire Council had trouble moving burger vans from outside its schools.
The committee was discussing a proposed bill by Frances Curran of the SSP which would introduce free school meals throughout Scotland's primaries, as well as a bill to introduce more healthy eating in schools.
Mr Chambers, director of direct and care services at Glasgow City Council, is part of a Scottish Executive expert working group looking into the issue.
"Everyone is dedicated to the health agenda, but my concern is a future reduction in secondary school meals uptake, either free or paid for," he said.
Mr Chambers said proposals from the group, which have been forwarded to ministers, include banning crisps, confectionery and snacks as well as sugary and carbonated drinks from schools by the end of 2009.
But he added: "I'm telling you as a caterer and an operator that you would have a future erosion in the uptake of secondary school children using school meals across Scotland.
"It's a political decision."
He said healthy eating initiatives had been introduced in Glasgow's schools, including taking chips off the menu four out of five days.
This was expected to lead to a 15% drop in secondaries in free school meal uptake in the coming financial year, while the figure for overall uptake was down 17%.
Mr Chambers said: "This is our consumers and customers - the children - responding to the pressure for a healthy agenda by leaving the school."
He warned that there could end up being a black market in non-nutritional foods, adding that he had previously seen chips being passed through school gates in Glasgow.
"I think there's a huge danger in going down this road, which is eminently understandable on the health agenda, but practically it could destroy the service," he said.
Cosla education spokesman Charles Gray suggested that "light legislation" could be a solution to the problem of burger vans outside schools.