Fonction MS Access Mid()
Exemple
Extrayez les caractères d'une chaîne, en commençant à la position 3 :
SELECT Mid("SQL Tutorial", 3) AS ExtractString;
Définition et utilisation
La fonction Mid() extrait certains caractères d'une chaîne (à partir de n'importe quelle position).
Syntaxe
Mid(string, start, length)
Valeurs des paramètres
Parameter | Description |
---|---|
string | Required. The string to extract from |
start | Required. The start position |
length | Optional. The number of characters to extract. If omitted, this function returns all characters from the start position |
Détails techniques
Travaille dans: | Depuis Access 2000 |
---|
Plus d'exemples
Exemple
Extrayez les caractères du texte d'une colonne (commencez à la position 4 et extrayez 6 caractères) :
SELECT Mid(CustomerName, 4, 6) AS ExtractString
FROM Customers;