Documentazione Invantiveparte di invantive cloud
Forum di supporto InvantiveAccedi / Registrati

IS_NUMBER

Sintassi

%%{init: {
  'theme': 'base',
  'flowchart': { 'padding': '7', 'nodeSpacing': '20', 'rankSpacing': '20' },
  'themeVariables': {
    'fontSize': '11px',
    'fontFamily': 'Arial'
  }
}}%%
flowchart LR
    Start((START)) --> IS_NUMBER[IS_NUMBER]:::quoted
    IS_NUMBER --> End((END))

Scopo

La funzione SQL IS_NUMBER restituisce true quando un valore rappresenta un numero valido. Un numero valido può essere convertito in un valore number utilizzando TO_NUMBER.

Parametri:

  • Input (ANY): valore per verificare se è possibile una conversione in number.
  • Formato (opzionale, varchar2): maschera di formattazione; il valore predefinito è il formato numerico configurato. L'elenco delle maschere di formato è disponibile in Format Masks.

Restituisce: true quando il valore può essere convertito in un numero, false in caso contrario.

Esempi

L'esempio seguente determina se '1234567890' può essere convertito in un number:

select is_number('1234567890')

----------------
true

L'esempio seguente determina se 'A123' può essere convertito in un number:

select is_number('A123')

----------------
false