Click to See Complete Forum and Search --> : Replace Database Field in Crystal Reports
February 21st, 2000, 03:54 AM
I've linked the crystal report to a database, now i need some help in manipulating the database field. For example,the field consists of "P" (stands for PASS) or "F" (stands for fail) but i want to display PASS / FAIL instead of P/F ...can someone help me on this? do i need to use a formula or something? i'm very very new to crystal reports... Thankx
emails will be welcomed. pls email to this address zijing@singnet.com.sg
TH1
February 21st, 2000, 05:49 AM
yes. you need to use a formula
do the following
on the menu goto Insert-> formula field.
in the formula text type
if {Query.fieldname}="P" then
"Pass"
else
"Fail"
where fieldname is the field you are checking against.
Save the formula and place it on your report.
Hope this helps
February 22nd, 2000, 11:41 PM
erm...the way u suggested can't work...are there any other ways? i tried inserting the formula on the specific section but it still dosen't work. The database field is of type char and length 1 as i've said earlier, i wanted the value "P" to be displayed as "Pass" which is of length 4. i've tried putting this in the details section code
if Field2.value = "P" then
Field2.value = "pass"
end if
this still dosen't work whereby Field2 is a report field. ..really at a loss now ...can u pls leave ur email address TH1?
TH1
February 23rd, 2000, 04:20 AM
First of all what version of crystal reports are you using.
I use version 7 and I use formulas for this sort of thing all the time.
If you want to Email me directly send to
hayes_tony@nospam.hotmail.com
remove nospam
codeguru.com
Copyright Internet.com Inc., All Rights Reserved.