I bought a new knock sensor on eBay last year for a very low price or around $12 with shipping.
Did the job fine - didn't look any different to the one that it replaced to be honest.
If you are strapped for cash just get this one:
NISSAN KA24DE 2.4L SR20DE 2.0L VQ30DE 3.0L Knock Sensor US $7.79 FREE - Standard Shipping
It's not too bad to change as long as you have a wobble bar extension set - you can get cheap Chinese sets at Harbor Freight if you need some.
When you say lose gas do you mean you have a leak or it's just disappearing?
If you have a leak check the tank around the area of the support strap on the passenger side - they have a known defect where they crack. Big job to change unfortunately, as I've just gone through the very same problem
