Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQuery
Message
 
 
To
09/05/2008 09:25:25
General information
Forum:
Visual FoxPro
Category:
Stonefield
Title:
Re: SQuery
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01308261
Message ID:
01316065
Views:
20
Hi Doug,

Is there a way to see the generated SQL? It didn't work quite correctly for me.

I think I need something like

select P.LastName, P.FirstName, Ph.HomePhone from People P LEFT JOIN Phones Ph on ...

select TempCursor.*, Ph.CellPhone left join ...

In other words, I need a series of left joins. They may be combined all together using derived tables idea.

However, specifying subtables and LEFT JOIN resulted in sort of the Inner join instead of the desired result.

Do you see a way to solve this?

I also found couple of problems (bugs?) which I sent to the support e-mail. Do you want me to list them here as well?



>Hi Naomi.
>
>>I've created SubTables for all various kinds of phones. My question is - can I use several subtables of the same table in the same report? It's essentially the same field (Phone), so somehow I need to have it aliased differently.
>>
>>Is it possible?
>
>Yes. A subtable essentially becomes an aliased name for another instance of the same table. For example, suppose you have subtables of Phones called HomePhone (with a subtable filter of HomePhone.PhoneType = 'Home') and CellPhone (with a subtable filter of CellPhone.PhoneType = 'Cell'). Including both of these in a report would result in a SQL statement similar to this:
select Contacts.Name, HomePhone.PhoneNumber, CellPhone.PhoneNumber
>  from Contacts join Phones HomePhone on (whatever)
>  join Phones CellPhone on (whatever)
Doug
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform