For example I have heard the sentence If I was your mother You would be a good son and also If I were your mother ....... Which one of them is ok?
You can use either. Personally, I prefer "If I were", but I recognise that through common usage "If I was" is also now acceptable. The subject is covered here.