The official language of Shanghai is standard Mandarin Chinese, also known as Putonghua. The traditional dialect of the city is Shanghainese, a dialect of Wu Chinese quite different than Beijing dialect of Putonghua. If you have some teaching jobs in Shanghai you should prepare yourself well.
Shanghainese used to be the common language of the Wu region before the 1980s. The influence of Shanghainese in the Wu-speaking area (mainly in Zhejiang and Jiangsu province) has decreased due to the promotion of Mandarin. As a result, the young generation of Shanghai is no longer familiar with the local dialect, but turns to standard Mandarin.
As a prestige dialect in the Wu-speaking area, Shanghainese is a hybrid between Southern Jiangsu and Ningbonese.