Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Looking up values
Message
De
09/02/2012 07:44:49
 
 
À
Tous
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Titre:
Looking up values
Versions des environnements
SQL Server:
SQL Server 2008
Divers
Thread ID:
01534966
Message ID:
01534966
Vues:
83
Hi

IN SQL I am often am looking up values to use in my Stored procedure.

like


SET @member_ref = (SELECT member_ref from MEMBER where MEMBERSHIP_NO = @membership_number1)
SET @individual_ref = (SELECT individual_ref from MEMBER where MEMBERSHIP_NO = @membership_number1)

is there a way to combine that into one select statement and is there any point . (ie is one statement more efficient)

Thanks

Nick
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform