You don't want to put 9v directly on the pin, the maximum is 5 volts for a board that is running on 5 volts! If you want to measure 9v you would use a voltage divider. The value you read will always be 5v divided by 1024 but if using a divider ( say with two equal value resistors to divide the voltage in half) 1024 would equal 10 volts. A search on voltage divider should yield more info on this
(John I think you need your morning coffee )