While I am able to understand the meaning of encoding and decoding from wikipedia, I am not able to understand why each programming language needs them? And if the answer is related to being able to read data from external source like a database, then why do many of them employ different encoding schemes?

E.x. Python has a default ASCII encoding  

 Java relies on the underlying O.S,  

 DB2 database has IBM-1252