Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Attempting a UNION with a memo field
Message
De
22/11/2005 22:41:14
Jill Derickson
Software Specialties
Saipan, CNMI
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows 2000 SP4
Database:
Visual FoxPro
Divers
Thread ID:
01071377
Message ID:
01071429
Vues:
26
Thanks Sergey. I guess i should have known to try that, since the Help message for that error states:

Unions between differing column types are not allowed when one of the columns is of Memo or General type unless UNION ALL is used.

But sine I was using the SAME column type, i didn't think that was the problem.

Anyway, solved.

Thanks again, j

>Jill,
>
>The UNION performs implicit DISTINCT on the result set and it's not allowed for those type of fields. Change it to UNION ALL which doesn do DISTINCT.
>
>>
>>I am trying, and failing, to include a memo field in a UNIONed SQL SELECT. I've pared the statement down to the following:
>>
>>
>>SELECT app_activitycomments ;
>>	FROM appointments ;
>>	INTO CURSOR c_Temp ;
>>	WHERE !app_activity AND app_clientfk > 0 AND app_GroupnameFK=0 ;
>>	UNION ;
>>		SELECT app_activitycomments ;
>>			FROM appointments;
>>			WHERE !app_activity AND app_clientfk=0 ;
>>			UNION ;
>>				SELECT app_activitycomments ;
>>					FROM appointments ;
>>					WHERE app_activity
>>
>>
>>and i get the error:
>>
>>"Operation is invalid for a Memo, Blob, General or Picture field"
>>
>>I can't have a memo in a UNION SQL SELECT statement?
>>
>>TIA, j
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform