In the TNG episode "The Defector" Data indicates (to a Romulan visitor) that Romulan Ale is not available to be replicated:
SETAL: I thought it would bring me some comfort. But these are not my stars. Even the heavens are denied to me here. Synthetic swill. I don't suppose your food terminals would be capable of producing a Romulan ale?
DATA: I am afraid they would require the molecular structure of the beverage in question. And, as you are no doubt aware, our knowledge of your planet is quite limited.
However, shortly afterward the holodeck is used to create a convincing replica of the Romulan landscape. It's pretty clear that there has been some trade and contact between the Federation and Romulus over the years, dating back to TOS and before, so...
How is it that Data can access a program for an entire planet but not access a simple formula for an ale?