Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to CAST empty string into memo for SQL?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01531130
Message ID:
01531184
Vues:
55
>>Hi,
>>
>>I think I have known this (or asked this before) but forgot (sorry). How do I cast an empty string into a memo type column when sending SQL Select to SQL Server? For example, in VFP I would do it like the following:
>>
>>
>>select *, cast( '' as MEMO) As MyMemoFld from MyTable
>>
>>
>>What should be in place of MEMO in the case of SQL Server? TIA.
>
>Everything with length bigger than 255 will be converted to memo:
>
>select *,
>       cast( '' as varchar(256)) As MyMemoFld
>from MyTable
>
>----
>select *,
>       cast( '' as varchar(max)) As MyMemoFld
>from MyTable
>
Thank you, Borislav.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform