>>I have the following view
>>create sql view vwconspessoa as ;
>>SELECT Pessoa.nmpessoa,;
>> IIF(Pessoa.idpessoa=1,"Física","Jurídica") AS idpessoa,;
>> Municipio.nmmunicip, Atividade.nmatividade, Pessoa.nrfone, Pessoa.nrfax,;
>> Pessoa.nmemail, Pessoa.nrpessoa;
>> FROM advbmala!pessoa, advbmala!municipio, ;
>> advbmala!atividade ;
>>WHERE Pessoa.nrmunicip = Municipio.nrmunicip AND ;
>> Pessoa.nratividade = Atividade.nratividade AND ;
>> UPPER(pessoa.nmpessoa) LIKE UPPER(?parm_condicao) ;
>> ORDER BY Pessoa.nmpessoa, Municipio.nmmunicip
>>
>>Every time I change the parm_condicao I get the message "view definition has been changed" (error 1494)
>>
>>The parm_condicao assumes values like 'p%' or '%de%'
>>
>>What is wrong?
>
>Most likeley, the parameter has absolutely nothing to do with it. The IIF() function in your select is the culprit. Different results sets are resulkting in columns of varying width from REQUERY to REQUERY. Try instead:
>
>IIF(Pessoa.idpessoa=1,"Física ","Jurídica") AS idpessoa,;
>
>
>Notice the two trailing spaces after "Fisica" to ensure that the field is always the same size.
Erik, you are right the problem is the different size of "Fisica" and "Juridica". I spent many hours trying to find the error.
Many thanks
Antonio Carlos Kleinübing
Systems Analyst