If you see sap coming out of a tree it could be caused by many different things. Damage to a tree trunk or limb can cause sap to leak out. This is natural wound protection for the tree. The sap comes out and covers up a wound to prevent plant pathogens and insects from getting in the tree. However, when you have multiple wounds on a tree (like in figure 1) you most likely have several insects that are boring into (or out of) your tree. Some trees can survive having a few insects damaging their trunks and bark so your tree is not always doomed.
Figure 1. Pitch tubes of the black turpentine beetle, Dendroctonus terebrans (Olivier), occur on the lower trunk and may be as large as a half dollar. Photograph by Wayne Dixon, FDACS-DPI, www.forestryimages.org.
If you would like to determine what is causing the problem you can search for the name of your tree (pin oak, loblolly pine) with the damage (1/4 inch holes with wet sap, with dry sap, with sawdust) on the Featured Creatures website and hopefully come up with a match for your problem. The Featured Creatures website has almost 50 publications that showcase insects that cause damage to trees.
If you do not find an answer on the Featured Creatures website please visit your local County Extension Office for assistance.