Using inline SQL with a JOIN

Using inline SQL with a JOIN

Postby ecg4212 » Thu 20 Dec 2012 21:20

I am using dotConnect for Oracle Pro trial version with direct connect and .NET 4.0. I downloaded it 3 days ago, so it is whatever version was available then. I have no problem retrieving data with simple inline SQL statements. When I add a JOIN, the data call times out. I know the SQL statement works because it works in SQL Developer. I am, of course, using CommandType.Text.

Does dotConnect for Oracle work with JOIN statements?


Here is my SQL statement:

SELECT CM.AGR_013_CONTRACT_TYPES.AGR_013_CODE,CM.AGR_013_CONTRACT_TYPES.AGR_013_HEDGE_POS_CTGRY,CM.AGR_005_DAILY_POSITIONS.AGR_005_LOCATION,
CM.AGR_005_DAILY_POSITIONS.AGR_005_LOCATION_DESCRIPTION,CM.AGR_005_DAILY_POSITIONS.AGR_005_COMMODITY_DESCRIPTION,CM.AGR_005_DAILY_POSITIONS.AGR_005_COMMODITY,
CM.AGR_007_CONTRACT_SCHEDULES.AGR_007_REMAINING_QUANTITY, CM.AGR_007_CONTRACT_SCHEDULES.AGR_007_DELIVERY_DATE,CM.AGR_007_CONTRACT_SCHEDULES.AGR_007_APPLY_STATUS,
CM.AGR_007_CONTRACT_SCHEDULES.AGR_007_PRICE_STATUS from CM.AGR_013_CONTRACT_TYPES
left outer JOIN CM.AGR_005_DAILY_POSITIONS on CM.AGR_005_DAILY_POSITIONS.AGR_005_LICENSE_GUID=CM.AGR_013_CONTRACT_TYPES.AGR_013_LICENSE_GUID and CM.AGR_005_DAILY_POSITIONS.AGR_005_DATASET_GUID=CM.AGR_013_CONTRACT_TYPES.AGR_013_DATASET_GUID
left outer JOIN CM.AGR_007_CONTRACT_SCHEDULES on CM.AGR_007_CONTRACT_SCHEDULES.AGR_007_LICENSE_GUID=CM.AGR_013_CONTRACT_TYPES.AGR_013_LICENSE_GUID and CM.AGR_007_CONTRACT_SCHEDULES.AGR_007_DATASET_GUID=CM.AGR_013_CONTRACT_TYPES.AGR_013_DATASET_GUID


Thanks,
Eric
ecg4212
 
Posts: 2
Joined: Thu 20 Dec 2012 20:46

Re: Using inline SQL with a JOIN

Postby Shalex » Wed 26 Dec 2012 13:34

ecg4212 wrote:When I add a JOIN, the data call times out.

Please set a bigger value in the CommandTimeout property of the OracleCommand object (zero value means no limit) and notify us about the results.

ecg4212 wrote:Does dotConnect for Oracle work with JOIN statements?

Yes, it does.
Shalex
Devart Team
 
Posts: 7654
Joined: Thu 14 Aug 2008 12:44


Return to dotConnect for Oracle