Under Regulation L, you can drill through the middle of solid wood joists in the UK Read it as part of my current electrical course fairly recently, but in America you can't drill their composite (not solid) absolutely correct on the composites with an exception if you can get an engineer to approve a location that he deems is safe(usually within 6 inches(15cm) from the vertical support. It's covered in building code and not electrical here. Generally drilling has to be 1/3 or less of width of the beam /wood being drilled and done in the center of the piece being drilled. that is a 2x6 could have a 2 inch max hole drill dead center. More of a concern for plumbers than sparkys here. Notching is allowed with protective metal plates for the wiring but I prefer holes over notching as it is logic that in the place of the notch you are creating a different size of beam if you notch deeply and a source of weakness in support.