Nissan Repair Questions? Ask a Mechanic for Answers ASAP
Well, the Nissan sensors fail all the time so an aftermarket one couldn't be worse, and virtually all of them are made by the same two companies. If you google Nissan 3.3 Knock sensor relocation there is a way to replace the knock sensor into a different location and simply add in a new pigtail to connect to it. It makes it much easier to replace if you need to do it again.
Well, they set the code usually for three reasons. Either the knock sensor is bad, there is corrosion on the connector, or the engine is noisy and causing the knock sensor to activate way too much. Normally you can hear if the engine is too noisy (loud valvetrain noise will do it) so if it still sounds pretty quiet, you probably need a sensor and connector.