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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linking Remote Views 1

Status
Not open for further replies.

k1ma2002

Programmer
Aug 14, 2002
7
0
0
US
Does anyone know how to link remote sql views in a report? I can't seem to get it to work and I'm not sure why. I have a sql table with 335 fields in it which is too many to have in one view (255 limit I think). So I split the table up into 2 views and included the id in both. Now I want to link the two in a report and it doesn't seem to want to link the two. I can't seem to find much documentation either so I thought I'd ask. Any help would be greatly appreciated.

Kevin
 
Kevin,
Don't be confused by the View aspect of the problem. (When you have a view open, you deal with it just like any other table!)

To re-link the two tables, you'll need create a relationship from one table into the other, which means you'll need to create a temporary index on the second "table".

Select View2
Index on commonfld tag commonfld
Select View1
SET RELATION TO commonfld INTO view2 ADDITIVE

Assuming the views have a one-to-one relationship, then moving the record pointer in View1 (manually or automatically in the report writer) will also move it in View2.

Rick
 
That is actually more than I thought you could do, but is there a way to create a persistent relationship?
 
No, because the index is only temporary - it will go away when you close the view, and all persistant relationship would need a permanent index.

Rick
 
build a local view based on the remote views
 
MCTCO,
The problem with that idea, is that Local views as well as Remote views, tables, and cursors ALL have a maximum field limit of 254/255.

Rick
 
do you need them all for your desired query? You can build many views depending on the need.
 
Yes, unfortunately I do need all the fields in the SQL table and worse than that I have/had no control over the design of the table to begin with or I may have never had this problem. The SQL table I'm accessing is being used by another program and so if I were to change it I would also have to get it retrofitted, update the install program, etc and I don't have permission to do this.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top