Exploring Index And Query Optimization Techniques For Database Applications