Tuesday, February 24, 2009

No more avoiding databases.

Databases are something that I've managed to avoid working with, and are a gaping void in my programming experience. Luckily, for my iPhone project, I've been told they want a database of every event stored. Databases cannot be avoided anymore, I guess.

I found the SQLiteBooks Example for the iPhone and an excellent collection of tutorials for the iPhone SDK in general. Up until this point, my main sources of help have been the example code and documentation sources from Apple. Expanding my pool of help resources is going to let me learn a lot more a lot quicker.

After looking through the SQLiteBooks code, and looking up every sqlite3 call it makes, the clouds around this previously mysterious database subject are being drawn back a bit. Playing around with sqlite3 from the command line to experiment reminds me of using irb to learn Ruby.

The switching between left and right brain activity is described thoroughly in Pragmatic Thinking and Learning. This applies well to learning a new API or programming language. You get coding a good example (context-rich environment) and read the code and experiment with it. Then you read through some documentation sources about what each part does--the analysis part. You apply this knowledge in context by experimenting a little further in your sandbox code. In turn, by swapping back and forth between your right and left brains, you develop intuition and learn much faster and learn more in-depth.

The discovery of new features is done in the analysis and how they work is done through experimentation. This gives rise to the "code it to figure out how it works" philosophy, which I've used to learn some of the weird nuances of C++.

No comments:

Post a Comment