On Wed, Sep 07, 2005 at 07:23:59AM -0700, Jay Siegel wrote: > I'd like to create another table with > "AverageSalaries" combining the ID's from (a) and (b) > into a unique 8 byte ID. I'm thinking that the > columns would be "SuperID" (8 bytes integer created by > combining each ID from the city table with the ID from > each job table and "AveSalary" which is the average > salary for that job in the given city (based on the
That seems bizarre. Typical RDBMS practice would be to just use a two-column composite primary key. > ID's). The reason for combining the ID's is to create > a unique ID that can be a key for quick access. > > Again, this is a simplistic example but demonstrates > the issue I'm dealing with among multiple tables. Is > this combining of ID's the best way to handle this > "join" when performance is required? Can an 8 bytes Did you measure a serious performance problem when joining on two separate columns? -- Andrew Piskorski <[EMAIL PROTECTED]> http://www.piskorski.com/