Squash – Pickleworm
Q: Last year my yellow squash grew fine but they had little green worms inside when you cut the squash open.
A: My guess is that you had pickleworms in the squash. They are the larvae of a brownish-yellow moth. According to the University of Florida, the moths are active only at night. When they are a few days old, females begin laying eggs in small clusters of two to seven, mostly on buds, flowers, and other actively growing plant parts. Each female moth can produce 300 to 400 eggs. Young larvae are often found in flower buds. They burrow into the fruit as they grow larger.
Pickleworm also affects canteloupe, cucumber and pumpkin.
You can get control by applying an insecticide on the individual fruit right after pollination. Do this in the evening when pollinating insects are not around and try to spray ONLY pollinated fruit (the flower will be wilting by late afternoon).
Another option is to cover plants with floating row cover (click for sources) after they sprout.
After plants begin to flower, remove row covers during the day to allow for pollination, and replace covers in the late afternoon to prevent egg-laying by the nocturnal moths.
Regular sprays of Bacillus thuringiensis (B.t.) click for sources) can be useful.
Another option, particularly for canteloupe, is bagging.