Print Page | Close Window

Unlinkable tables???

Printed From: Crystal Reports Book
Category: Crystal Reports 9 through 2020
Forum Name: Tips and Tricks
Forum Discription: Have you learned some great tricks to share with the group? Post them here!
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=2654
Printed Date: 18 May 2024 at 11:14pm


Topic: Unlinkable tables???
Posted By: pellis
Subject: Unlinkable tables???
Date Posted: 19 Mar 2008 at 3:42pm
I need help with this.  I can't seem to figure out a simple way to accomplish what I want.  I am using Crystal Reports XI.  I have a table on a database that contains the value of a zipcode.  The field is memo so it does not show up on the database expert as a field that you can link to another table.  I have a zipcode table on a different database that has a field for the zip and the state that matches that zip code.  Ideally I would like to link the zipcode field from the zipcode table to the value field in the other table.  Looks like this:
 
|---------------------|                 |---------------------------|   
|Profile_values    |                 |   zipcode_Number     |
|---------------------|                 |---------------------------|
|   fid                    |                |     zipcode                 |
|   uid                   |                |     State                    |
-----------------------                  ---------------------------
 
Value is a data field from Profile_Values but it does not show up on the database expert when I link the tables.  If it did I could link value to zipcode.   Can anyone offer me a way around so that I can get the state (zipcode_number.zipcode) that matches the value of zip in the Profiles_values.value field?  Any help is deeply appreciated.  Thanks.



Replies:
Posted By: andymc
Date Posted: 20 Mar 2008 at 10:34am

pellis,

Create a formula:
trim({Profile_values.uid})
 
Then create a subreport that uses the Zipcode_Number table and put State on the detail and supress all other sections.  On the subreports Link tab link the subreport from the @zip formula on main report to the zipcode field on the subreport.
 
 
 
 


-------------
Andymc


Posted By: pellis
Date Posted: 21 Mar 2008 at 10:06am
Thanks so much.  I can't wait to give this a try.  I will let you know how it turns out.   Thanks again.
 
pellis



Print Page | Close Window