Getting on well with co-workers is very important to anyone who wants a happy and successful time at work. Most people spend more time with their co-workers than anyone else in their lives, something that we rarely consider. Those people are directly related to your success and your well-being in the work place, because what they say, do and think about you will always be an important factor in their relationship with you. Everyone in a work environment is a cog in a much larger machine, and if one of those cogs doesn't fit well with another it can have a lasting impact on not just the success of those individuals, but the success of the entire team they are a part of.
The first place you should start when dealing with co-workers is to deal with their unique characters traits. Often you'll find that people have habits and tendencies that can annoy you quite easily, and whilst you could argue that those people should be more considerate of you it's probably easier for you to simply learn to deal with those problems yourself. The workplace is a diverse environment, and you are unlikely to find a single person that you will get along with entirely. Then of course there are the issues of race, gender, age, nationality and religion.
You may consider that people of different race, gender, age, nationality or religion are quirky, and prone to strange habits. Whilst this may be true, it is also true that everyone of every different denomination wants the same things from life; a safe place to live, ongoing employment, success and financial security. Whether they act or dress the same way as you, and regardless of their unique traits and qualities, they share a lot of the same aspirations as you. And what a bland world it would be if everyone was precisely the same as everyone else!
If you discriminate against fellow co-workers because of their race, gender, age, nationality or religion, or for any other reason, it's safe to say that you're putting your success at work in jeopardy. There are a host of situations where being discriminatory towards other staff can lead to your failure. For example, if you were put up for a promotion to a managerial position and your co-workers were asked whether they would be happy with your appointment, would they give their support to someone that had treated them badly simply because of the differences between you?
Of course there are other areas where your relationship with co-workers can break down. Perhaps another employee is emotionally immature, and finds it difficult to work with you because they fear that revealing any aspect of their job to you may result in a loss of job security? Or maybe another co-worker simply doesn't understand something you are trying to explain to them, no matter how simply you break it down? Or maybe they just don't care as much as you do about doing their jobs well? The problems inherent with difference in emotional maturity, intelligence and job dedication are hard to deal with at the best of times, but again these people could make or break your career depending on how you interact with them. Patience, and calm, can go a long way in facilitating healthy working relationships with the most difficult of co-workers.
Your success in the work place requires that you accept and embrace everyone around you, regardless of whether you like or dislike them on a personal level. Forming healthy relationships with co-workers that you may work with, even if it's unlikely, will make your job easier and more successful in the long run. Be personable; engage in small talk on coffee breaks, invite them out for lunch, and learn about them as a person, if only to give you a better understanding of how they tick.
Never come across as threatening, bossy or intrusive; consider how you would like to be treated and treat others accordingly.