Where the name originates:
Oedipus is a character of Sophocles' drama, Oedipus Tyrannus. He was born to King Laius and Queen Jocasta of Thebes, but because the Pythia in Delphi predicted he would kill his father and marry his mother, he was given to shepherds as an infant to be killed. They however let him live, and he ended up growing up in another kingdom, raised as the son of King Polybus of Corinth. When Oedipus grew older, he heard about the prophecy and left the kingdom to prevent it from coming true, believing Polybus to be his father. His fate took him back to Thebes, where he accidentally met the king at a crossroad, and after a heated argument, killed him. When he arrived at Thebes, the city was under the oppression of a Sphinx. Oedipus solved the Sphinx's riddle and killed the creature, riding the city of it. The city welcomed him and he married the widowed queen, Jocasta, without realizing they were related. When they found out what really happened, the queen killed herself and Oedipus gauged his eyes out and left the city.
Electra complex was named after Electra, daughter of Agamemnon, who helped her brother kill their mother in revenge for their father's death.
Freud and Jung
Freud defined the complex as a child’s (sexual) desire for the mother, and jealousy and anger for the father, regardless of the child’s gender. Jung defined the complex as a boy’s desire only, and named the complex of girls wanting to marry their father Electra complex, but otherwise their views were very similar.
They agreed it was a stage of psychological development in children, between the ages of 2-5, when they would contend for the affection of the opposite-gender parent with the same gender parent, wishing to replace them. According to them, all children go through these stages, and it would be resolved by entering the next stage of development, penis envy for girls and castration anxiety for boys. This is an important part of the development of their sexuality, where in the end they would identify with the same-sex parent, learning their gender role. If for some reason bad influences affect the children in this stage, it could cause neurosis, pedophilia or homosexuality.
A positive Oedipus/Electra complex is when they are attracted to the opposite-gender parent. A negative one is when they are attracted to the same gender.
Contemporary psychologists
Very few of the contemporary researchers question the existence of the Oedipus complex and agree that a hostility against the same-gender parent can be described in most cases, but they also agree that the desire for the parent is not sexual but merely for affection and attention. They also agree that both the positive and negative forms can occur. Most also do not think they would have lasting effects.
According to Martin Daly and Margo Wilson, the Oedipus complex yields few testable predictions because they found no evidence of the Oedipus complex in people. Grose though went as far as to call the theory disproven and unnecessary, nothing more than an explanation of the socialization of children. Incest is nearly universally forbidden, and not primary because of the genetic effects but because of instinctual sexual aversion against it.
On a last note: Oedipus did certainly not have Oedipus complex, whichever way it is described, as his union with his mother was unwanted, unintentional and deeply regretted. Nor did Electra have sexual desire for her father. The Oedipus story "depicts a troubling and seemingly universal dimension of human behavior; the way we unwittingly create the fate we fear and abhor...numbers of therapists realize that people are inextricably shaped by the specific relational contexts in which they are raised and later inhabit." (Jeffrey B. Rubin, Ph.D.)