Opening a window on a aircraft in flight is not a terribly good idea since the cabin is pressurised at altitude. If a window were to be opened it would cause raped depressurisation, which can make the rest of the flight very uncomfortable for the other passengers and difficult for the pilots. Only a few of the cockpit windows can be opened (and then it is strongly advised to do this only when the aircraft is on the ground.)
I don't understand why you are asking.

Have you been on a plane where this was possible?