Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Read schema to get numeric size
Message
Information générale
Forum:
ASP.NET
Catégorie:
Bases de données
Versions des environnements
Environment:
VB 8.0
OS:
Windows XP SP2
Network:
Windows XP
Database:
MS SQL Server
Divers
Thread ID:
01526427
Message ID:
01526450
Vues:
65
This message has been marked as the solution to the initial question of the thread.
>>>I need to determine the size of numeric fields in SQL tables. I know how to get the decimal positions but I cannot find out how to determine the significant positions. Some thing like Numeric(???,4) I need to determine the ??? value. How can I retrieve this information from the SQL schema?
>>>
>>>Thanks
>>>
>>>Glenn
>>
>>
>>SELECT NUMERIC_PRECISION,
>>       NUMERIC_SCALE
>>FROM INFORMATION_SCHEMA.Columns
>>WHERE Table_Name = 'YourTable' AND 
>>      Column_Name = 'ColumnName'
>>
>
>Thanks Borislav but this does not return the ???. For instance lets say that you have a field defined as (5,2) and you run this query. it will return 10,2
>
>Truly a SQL mystery.
>
>Glenn


Are you sure?
You maybe watch NUMERIC_PRECISION_RADIX instead of NUMERIC_PRECISION?
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform