exception handling

i am a beginner in yii so can you please tell me where to write exception handling code in yii.

I would recommend to read the topic Raising Exceptions in the Definitive Guide.

Also a good way to learn is to look into source code of existing projects like the Yii playground or into (open source) projects in the Yii-powered applications area of the forum.