Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SELECTing null constants
Message
 
 
À
07/03/2002 04:17:54
Alan Law
Apocalypse Enterprises Inc.
Victoria, Colombie Britannique, Canada
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00629338
Message ID:
00629584
Vues:
17
Well, I can not say, it was my method :) I picked this idea earlier from this forum and used in couple of situations like this.

Thanks.

>Nadya,
>
>Thanks a lot for the fast answer. I knew there had to be cute trick to solve this, and your method is slick. It also solves a bunch of other related issues that I was clumsily working around.
>
>>>Hi folks,
>>>
>>>I often use the construct:
>>>
>>> SELECT *, 000 as extrafield from . . .
>>>
>>>to build a table with extra columns which get filled in later by program logic.
>>>
>>>Problem is, the 'extrafield' cannot hold .NULL.
>>>
>>>Is there a SQL trick to allowing extrafield to hold NULL (while keeping its N3,0 property), or do I have to suffer an ALTER TABLE after the SELECT ?
>>>
>>>Thanks for any ideas on this,
>>
>>select 0
>>Create cursor dummy (MyField1 C (10) Null, myField2 ...)
>>append blank
>>
>>select tabe1.*, dummy.* from table1, dummy ...
If it's not broken, fix it until it is.


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

Click here to load this message in the networking platform