index we create for a column on a table, nd when we create that, internally the indexes, which r key,field values with that column value & probably the corresponding record addr, r created and stored in some tree structure. and wen we do a select based on this column value, db 1st searches this tree, and then picks the corresponding record from the table. It makes select much faster.
so, if you have a table, and it is having huge no of records, and mostly u fetch records based on a particular column(field) value, i.e, that column is in where clause of the select st, then if u create an index for that column, select queries will be multiple times faster. On Thu, Sep 8, 2011 at 2:16 AM, bharatkumar bagana < [email protected]> wrote: > @piyush: > can u pls elaborate the explanation for option d) ... > > > On Wed, Sep 7, 2011 at 9:07 PM, Piyush Grover > <[email protected]>wrote: > >> Option a) i didn't understand properly, please elaborate!! >> >> Option b) certainly yes. >> >> Option c) No (remember, the size of the table is subjective) >> >> Option d) yes (use index on the column used in the where clause) >> >> >> >> >> On Wed, Sep 7, 2011 at 8:58 PM, Mani Bharathi <[email protected]>wrote: >> >>> when is index of a table used? >>> >>> a)when table is less range of values >>> b)when table is used frequently >>> c) when the table is small >>> d)when we use join statement with select and where clause. >>> >>> -- >>> You received this message because you are subscribed to the Google Groups >>> "Algorithm Geeks" group. >>> To view this discussion on the web visit >>> https://groups.google.com/d/msg/algogeeks/-/vtHvd8sE1AUJ. >>> To post to this group, send email to [email protected]. >>> To unsubscribe from this group, send email to >>> [email protected]. >>> For more options, visit this group at >>> http://groups.google.com/group/algogeeks?hl=en. >>> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Algorithm Geeks" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]. >> For more options, visit this group at >> http://groups.google.com/group/algogeeks?hl=en. >> > > > > -- > > **Please do not print this e-mail until urgent requirement. Go Green!! > Save Papers <=> Save Trees > *BharatKumar Bagana* > **http://www.google.com/profiles/bagana.bharatkumar<http://www.google.com/profiles/bagana.bharatkumar> > * > Mobile +91 8056127652* > <[email protected]> > > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.
