want to know the coding of h ow to define connection of SQL database wid deplhi so that i can insert data in database

You need to be more precise when you post questions of this sort. Brief answer is - hard to tell unless you tell us which DB. Unless it is something really obscure you should have no trouble connecting to it using ADO. There is no dearth of ADO components around that would do the job. As a first step I suggest going to Torry and checking out what is on offer. I think you are bound to find a freebie that will do what you are after - this is not a rocket science sort of problem