sql server 2005 performance: graphic full list where statement


we have twin tables:




  • document: id, title, document_type_id, showon_id

  • documenttype: id, name

  • relationship: documenttype hasmany documents. (document.document_type_id = documenttype.id)



we wish collect list request forms given showon_id.



we twin possiblities:



select documenttype.*
from documenttype
where documenttype.id (
name graphic document.document_type_id request where showon_id = 42
);

select documenttype.*
from documenttype
where documenttype.id (
name document.document_type_id request where showon_id = 42
);


our doubt is: improved graphic smaller record set contra retrieving whole list matter walking list initial match. (we speculation that's does ;-))



is opposite different databases, there common answer?



or there improved proceed doing it? (we .net land)



Comments

Popular posts from this blog

list macos calm editors formula editors

how hibernate @any-related annotations?

why does floated <input> control floated component slip over too distant right ie7, nonetheless firefox?