------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------
-- Ooooo --
-- ( ) --
-- ooooO ) / --
-- ( ) (_/ --
-- \ ( --
-- \_) Ooooo --
-- ( ) --
-- CHAPITRE 4 : Fonctions intégrées ooooO ) / --
-- ( ) (_/ --
-- \ ( --
-- \_) --
-- --
------------------------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------
/*
Références : - http://msdn.microsoft.com/fr-fr/library/ms174318%28v=SQL.90%29.aspx
- http://baptiste-wicht.developpez.com/tutoriels/microsoft/sql-server/datetime/
*/
--.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.--
--.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.__.-**-.--
use VolAvion
-- Fonctions de chaines de caractères :
-- Concaténation :
select pas# as [Numéro],
(Nom + ' ' + Prenom) as [Nom complet]
from Passager
-- len
select Nom,
len(Nom) as [Longueur]
from Pilote
-- LEFT, RIGHT
select Nom,
right(Nom, 2),
left(Nom, 3)
from Pilote
-- UPPER,LOWER
select Nom,
upper(Nom),
lower(Nom)
from Pilote
-- SUBSTRING
select Nom,
substring(Nom, 2, 3)
from Pilote
-- REVERSE
cour complété: */Lien de telechargement :