Subject | Re: [firebird-support] Primary Key and Index |
---|---|
Author | Martijn Tonies |
Post date | 2003-10-30T13:07:34Z |
Hi,
With regards,
Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird & MS SQL Server.
Upscene Productions
http://www.upscene.com
> I've got a table "EmpCalendar" that has a primary key on two fields:EmpNo,CalDate.
> Doing a select withYes.
> where EmpNo = <value> and CalDate = <value>
> uses the primary key - correct?
> As does a select withYes.
> where EmpNo = <value>
> - still correct?
> Should I create an additional index on CalDate, if I do frequent queriesYes. The index on EmpNo/CalDate cannot be used here.
> with
> where CalDate = <value>
With regards,
Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird & MS SQL Server.
Upscene Productions
http://www.upscene.com