District Judge Pratibha Rani asked Swamy to appear before Special CBI Judge O P Saini, who is dealing with all the cases related to the 2G spectrum allocation.
Swamy appeared before the court and requested the District Judge to transfer his case to the special court.
The Janata Party leader, who had sought a probe into scam, had also raised concern about the possible threat to national security arising out of allocation of spectrum to companies which had sold off their major shares to foreign firms.
Swamy had also sought the court's direction to appoint him as a public prosecutor to help the agency probe the case.
The CBI had earlier said it was investigating the angle of possible threat to internal security as per the concerns raised by Swamy.
The agency had told the court that it had been probing the 2G scam within the confines of the first information report registered by it.
Swamy, in his petition filed before the court, had said Swan Telecom and Unitech Wireless, which were allotted licences, had sold their major shares to two foreign firms Etisalat DB and Telenor, which is "a major threat" to national security.
"The first two licencees, Swan Telecom and Unitech Wireless, soon after the allocation of spectrum to them sold their controlling shares respectively to Etisalat DB and Telenor. The national security risk from these companies are highlighted by the Union Home Ministry as their connections go right into Pakistan," he had said.
Swamy had earlier sought the court's direction to the CBI to ask the Union Home Ministry, Research and Analysis Wing and other intelligence agencies to find out the bearings of 2G scam on national security.