Exploratory surgery was a medical procedure performed by a surgeon with the intent of discovering a health problem. This was generally done only when non-surgical means were unable to determine the cause of a problem.
Upon first examining Geordi La Forge in 2364, Doctor Beverly Crusher suggested performing exploratory surgery on him to possibly desensitize his brain to the pain caused by the use of his VISOR. La Forge declined, as it would affect how the VISOR worked, just as painkilling drugs would. (TNG: "Encounter at Farpoint")
In 2367, believing Odan's male host to have a parasitic infection, Crusher told him of the need for exploratory surgery to facilitate his diagnosis and treatment. He begged her not to, placing the preservation of Odan, the symbiont, over his own. (TNG: "The Host")
In 2371, Quark asked Doctor Julian Bashir to perform exploratory surgery on Grand Nagus Zek in order to determine the cause of his unusually generous behavior, which was later found to be caused by the Bajoran Prophets. His request was prompted by Bashir's inability to find anything wrong with him using various medical equipment. Bashir refused to do so, believing it to be unneccesary. (DS9: "Prophet Motive")