My music teacher sometimes tells me too memorize a song, but sometimes also tells me to read straight from sheet music. This confuses me as I am unsure which one is better practice. Is it better practice to read straight from sheet music rather than memorize it?
Very simply, playing a song from memory is one very useful skill, whilst being able to sight read is another very useful skill. It sounds like you have a wise teacher who is giving you a balanced curriculum!
It may be that as you progress, you find yourself favoring activities where one or the other is clearly more useful. In some situations (e.g. playing in an orchestra), instrumentalists are expected to be able to work from and refer to the score. In a live rock band situation, performing from memory (possibly including an element of improvisation) is more common.
There are other aspects of music theory that nevertheless tie these two approaches together. When playing from the score, you should learn to recognise the motion of the harmony; when playing back a song from memory, remembering the motion of the harmony will give you a good basis for recalling the piece (and for improvisation, where required).
As topo says, both are excellent skills to have. There are times when being able to play something accurately (and musically) straight from the dots is what's needed. Some musos earn good money using that particular skill - in recording studios, for example, where time is expensive.
Others will take time learning something, and be able to play it from memory. With some people, this happens as a natural course. It paid off for me on several occasions when my stand was knocked over, or the wind blew the charts all over the place. It also means that you, as a performer, can be more than someone whose head is stuck in the music - you can interact with the audience (or even those playing with you) which is all but impossible when sight-reading for the first time, however well you do it.
So, yes, your teacher is providing great bases for you and your playing. Well done! I'd take it even further, and encourage you to play something, then want you to continue in the same vein, without the music, and before you've memorised it. Sort of improvisation on the spot - busking, if you like. Another useful skill, that's often not within the remit.
Why should this confuse you? There are always different ways and approaches to reach a goal in your life - not only in music. And don’t try to find out which method is better.
There are even more methods:
1. reduce the harmony, 2. exchange the motifs, 3. play both hands or only one hand, 4. play a two voices piece both hands in octavas, 5. accompany with chords, 5. simplifying the chord or the accompaniment, 6. invent own solutions, 7. improvise above some motifs, 8. invent an own tune above a preludium etc.
These are all ways I’ve found out myself (inspired by Gounod’s AVE MARIA) and later I found them approved by other composers or pianists or editors.
The question is not which is the better methode the question is:
Which approach is better for which student for which piece of music!
These are instructions for developing completely different skills. To prepare for a performance, and to develop your memory, memorization is important. This allows you to put more feeling into the performance, and to improvise a bit if appropriate. It is difficult to "perform" if you are only focused on the sheet music. After some time the sheet music is just a road map to keep you on track but you shouldn't literally be sight reading. However, that being said, we sometimes get called on to read new stuff at a moment's notice (perhaps literally Moment's Notice). In these cases you need to be relaxed enough to play with some feeling and focused enough to follow the sheet music without making mistakes. You also need to be able to move on when you do screw up since time does not stop. For guitarists William Levitt have developed whole books of sight reading exercises with unusual rhythms and key changes just to keep you on your toes.