I've tried with last RASPBIAN STRETCH LITE (9.4 - 2018-06-27) in a PI3B v1.2 with a PI CAMERA 2.1, all fully upgraded (apt-get upgrade)
If this command doesn't detect the camera with "detected=1" like this:
pi@raspberrypi:~ $ vcgencmd get_camera
Then there is a connection problem. Check if the cable both ways are with the good side to the pins (and of course connected to the "camera" bus, not the "display" bus that are the same size).
(of course, after enable camera interface with raspi-config and rebooting)
If it didn't work, usually it's a hardware problem with the camera and the quick option is to change the camera with a new one.
If detected=1 but when trying to use raspistill shows this message:
pi@raspberrypi:~ $ raspistill -o test.jpg
mmal: mmal_vc_component_enable: failed to enable component: ENOSPC
mmal: camera component couldn't be enabled
mmal: main: Failed to create camera component
mmal: Failed to run camera app. Please check for firmware updates
Then the connections are ok, but the problem for sure is a hardware problem with the camera and you have to change the camera for a new one. Don't waste time trying to solve it because it's a defective camera. If you get a new one it will work.