I'm using an old version of crystal reports 8.5 and I'm having problems in showing a field in the details.
This report uses 6 tables in SQL Server database:
2 in database1:
tblRecibo, tblCanaisDistribuicao
3 in database2:
tblPessoas, tblMoradas, tblCodPostal, tblRamos
tblRamos.CodRamo
is an int datatype and I want to display it in the details section.
@N_Apolice
left(CSTR({tblRamos.CodRamo}, "000"),3)
It seems that I am not able to get any field from this table, yet I can access fields from other tables of the same database in the Group-Header section (This report uses tables from 2 different databases, and none of the table names used is repeated on both databases).
Already pressed the verify database button a few times... but the problem persists... is there a way to force it to check this table in particular? or this database in particular?(since there are 2 and it might be only checking the other one)
I have tested in SQL, if the query to get the data should return fields, and it does...
edit
I started to redo the whole report, and apparently that formula field is does not display its value correctly only if I add code to another formula fields (fields that use the same database but other data tables)
@Nome
Ucase({tblPessoas.Nome} & " " & {tblPessoas.NomeIntermedio} & " " & {tblPessoas.Apelido})
@Morada
Ucase({tblMoradas.Morada})
@CPostal
IF ISNULL({tblMoradas.LocPostal}) THEN
{tblMoradas.CPostal} & "-" & {tblMoradas.CPostalAux}
ELSE
{tblMoradas.CPostal} & "-" & {tblMoradas.CPostalAux} & " " & {tblMoradas.LocPostal}
In my mind this makes no sense at all...
edit2
these 3 fields are in the Group Header section
while the other one is in the details section... can that be the problem?
The fields that are in conflict for some reason are @N_Apolice (in the details) and @Nome, @Morada, @CPostal on the header.
All the other fields in the details section come from another data source and work well