Data Connectivity
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Data Connectivity
Message Icon Topic: Function to select from different table Post Reply Post New Topic
Author Message
jrisch
Newbie
Newbie


Joined: 10 Mar 2008
Location: United Kingdom
Online Status: Offline
Posts: 9
Quote jrisch Replybullet Topic: Function to select from different table
    Posted: 09 Dec 2008 at 6:46am
Hi, my problem is that the database driver (Remedy AR) doesn't support table linking. So, is it possible to create a function or formula that will allow me to retrieve data from a table with a parameter query based on a value in a record from my main table? E.g. my main table has a field "Incident Number". Can I create a function that uses it to return an associated field from a different table that also contains "Incident Number" as a field?
 
It's Crystal 9 I'm using.


Edited by jrisch - 09 Dec 2008 at 6:47am
IP IP Logged
rahulwalawalkar
Senior Member
Senior Member
Avatar

Joined: 08 Jun 2007
Location: United Kingdom
Online Status: Offline
Posts: 731
Quote rahulwalawalkar Replybullet Posted: 09 Dec 2008 at 6:55am
Hi
Do you have access to remedy database,you can create a view or a storedprocedure to link the tables,or write a sql  and use that as command object.
 
Cheers
Rahul
IP IP Logged
jrisch
Newbie
Newbie


Joined: 10 Mar 2008
Location: United Kingdom
Online Status: Offline
Posts: 9
Quote jrisch Replybullet Posted: 09 Dec 2008 at 7:37am
Unfortunately, I don't. Our company is so restrictive about access to the database.
 
The idea of creating an SQL command object is what i would like to do, but how can I pass a parameter based on a field in a record I've retrieved?
 
Thanks for you ideas.
 
Regards, J
IP IP Logged
rahulwalawalkar
Senior Member
Senior Member
Avatar

Joined: 08 Jun 2007
Location: United Kingdom
Online Status: Offline
Posts: 731
Quote rahulwalawalkar Replybullet Posted: 09 Dec 2008 at 7:41am

Hmmm

How about creating subreport,so you will have two different reports which have incidentnumber as common field and then you link the subreport using the incidentnumber from main report and reterive the data you want.
 
Cheers
Rahul
 


Edited by rahulwalawalkar - 09 Dec 2008 at 7:42am
IP IP Logged
jrisch
Newbie
Newbie


Joined: 10 Mar 2008
Location: United Kingdom
Online Status: Offline
Posts: 9
Quote jrisch Replybullet Posted: 09 Dec 2008 at 7:49am
Thanks I'll try that, though I was hoping to create a function so my team could use it almost as an additional field. Our problem is that we are migrating to Remedy 7 and a number of fields we are used to have been moved to different tables. As the AR driver doesn't support table linking, I was trying to find an SQL way around. Embedding SQL into a function semed like a good idea.
 
Thanks, J.
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.