You can use a cable like this. But be sure to connect the Black male jumper to the Black wire of the proximity sensor(GND). Similarly Red jumper to to the Red wire of the sensor (Power) and yellow jumper to yellow wire(SIGNAL) of the sensor. Leave the White jumper unconnected.
Please let us know if this helps,