The reason cucumbers, squash, muskmelons and watermelons should not be grown near each other is that they are all cucurbits and may cross-pollinate to produce weird franken-gourds. This myth does have some truth in it, but it is not good gardening advice.