Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
JOINing cursors
Message
From
18/06/1999 17:30:06
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Client/server
Title:
JOINing cursors
Miscellaneous
Thread ID:
00231628
Message ID:
00231628
Views:
41
I wish to create a local cursor, for reporting, from the data in two separate remote tables, each in their own database.

Database D1, table T1 holds Orders and ItemNo
Database D2, table T2 holds ItemNo and ItemDetail

Both tables are too large to consider bringing either down to my local machine in their entirity.

I currently do:

LcSearchString = “12345”

Handle1 = SQLConnect(“One”)
LcSQLCode1 = “select T1.Orders, T1.ItemNo FROM T1 WHERE T1.Orders = ?lcSearchString”
SQLExec(Handle1, lcSQLCode1, “Cursor1”)

Handle2 = SQLConnect(“Two”)
LcSQLCode2 = “select T2.ItemNo, T2.ItemDetail FROM T2 INNER JOIN Cursor1 ON T2.ItemNo = Cursor1.ItemNo”
SQLExec(Handle2, lcSQLCode2, “Cursor2”)

The above fails with a misleading message that is sort of the equivalent of file not found. I believe that the last SQLExec can’t see Cursor1

Any thoughts …
Next
Reply
Map
View

Click here to load this message in the networking platform