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

Joining a command object to a view

Status
Not open for further replies.

vtisgreat

Vendor
May 3, 2001
31
0
0
US
Hi, there are occasions when I want to create a specific re-usable command object that can be joined to another view.

I tried this in a very simple case, and when I show the SQL actually generated, it is not joined at all.

Can this be done?

Thanks,
Sean
 
Hi,
IIRC, using a mixed source for data ( Database View, Command Object) will cause the JOIN to take place at the CR level not at the database so it would not show in the generated SQL.

Do the join in the command object, not in the CR database expert.

Like this ( your code will vary greatly, this is just a concept example):

@MyCommand

Select view.field,table1.field from
view,table1
where
view.field = table1.field



[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