Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Verification on performance
Message
 
 
À
04/10/2010 11:46:25
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Versions des environnements
SQL Server:
SQL Server 2008
Application:
Web
Divers
Thread ID:
01483774
Message ID:
01483831
Vues:
22
>>Use 5 as a rule. Everything greater than 5 should be varchar.
>
>Are there any special consideration when updating the type of an actual field into varchar?

The safer method will be to create a new varchar field, update it with rtrim of old character field, then drop the original fied and rename the new field. This is assuming we don't have an index on that field.

It is always a good idea to use the good design from the beginning that changing the structure after the tables are populated.

----------------------------------------------------
Anyway, you may try changing one of the tables in SSMS, saving the script, then verifying the length of the data in the columns.
If it's not broken, fix it until it is.


My Blog
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform