Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sql view to Oracle doesn't return match records
Message
De
11/09/2000 09:39:34
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00412559
Message ID:
00414855
Vues:
20
Ok Mark. Thanks again.

>>>You may have to try:
>>>
>>>... WHERE RTRIM(Tartigen.CDARTGEN) = ?cCodigo
>>>cCodigo = "D0001234"
>>
>>¡¡¡ this works fine !!!
>>¿Will be, this method, optimized?
>>And so, ¿why my view works fine if value of codigo = '141111' and does not if value of codigo = 'D0001234'?
>>Thanks a lot Again Mark.
>
>It works because for that particular code, the value was padded with spaces to the right. In Oracle, spaces count when trying to find matches. If you are using remove views in VFP to send data to Oracle, VFP includes the spaces when it sends the value of a character field.
>
>That is why RTRIM works when you are trimming the spaces of the field value. In Oracle, "D0001234" is not equal to "D0001234 ". The only way around this is to create your own VFP update/insert procedure that send trimmed values to Oracle. You could also do this by creating triggers in Oracle that RTRIM the data being inserted or updated.
>
>It would be optimized if you have an Oracle index as follows:
>
>create index I_TARTIGEN_CDARTGEN on TARTIGEN (RTRIM(CDARTGEN)) tablespace schema_tablespace_name_or_index_tablespace_name_here;
Saludos,
A.G.P.
---------
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform