The Yes campaign moved ahead in the Survation survey when voters were asked to consider how they would vote in the referendum if they were certain Mr Cameron would be returned to Downing Street at the 2015 election.
The poll of 1,004 people found that 44% would vote Yes, 38% would vote No and 18% were undecided. When undecided voters are removed, Yes has a majority, with 54%, and No stands at 46%.
The survey, conducted between June 6 and 10, also showed a tight gap between the two sides when voters were simply asked to consider the question on the ballot paper: Should Scotland be an independent country?
It found that 39% would back Yes, 44% vote No and 17% are undecided. Excluding undecided voters puts Yes on 47% and No on 53%.
The result shows a narrowing of the gap between the two sides since the last Survation poll in May, when support for Yes was 44% and No stood at 56%.
Yes Scotland chief executive Blair Jenkins said: "The poll highlights the strong appeal of the guarantee that Scotland always gets the government we vote for only with independence - instead of being inflicted with Tory governments under the Westminster system.
"This independence guarantee is undoubtedly a major factor in persuading more and more Labour voters and members to vote Yes, and we believe this support will continue to grow in the run-up to September 18."