Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal XI field linking

Status
Not open for further replies.

olrac

MIS
Nov 23, 2010
16
CA
Hi,

I am trying to link two tables on the same field (employee_number). The employee numbers in the tables are the same but of different lenghts (on is 6 and the other is 50).
When I run the report it will not pickup anthing from the the table with the 50 char string (I used a left join). Is there a way to force the link?
Thanks
 
Are they both strings? If the actual number is the same, I think they should still be picked up--so are you saying that they appear exactly the same? If you place formulas using the employee number from each table in a report, like this:

len({table.employeeno})

...is the result the same? Or what is the result?

-LB
 
Hi,
Thanks for the quick response. I used the formula:
Left ({MT_PP_Employee_View_All.MT_Employee_ID_Text},6) = Left ({tblPatient.fstrPatientNum},6) and now I get the information I want.
I was under the impression that Crystal would handle the joins if the fields were the same type(string in this case) no matter the lenghts.
When I use the len function I get 6 from both databases. When I browse the field I get type=string, lenght=50 for ({tblPatient.fstrPatientNum}
and type=string, lenght=6 for ({MT_PP_Employee_View_All.MT_Employee_ID_Text}).

Thanks


 
Hi,
What database? Some engines pad strings to the defined length and mis-matched length strings may not be seen as equal by the database's parser.



[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top