Hi,
While joining two different oracle db tables,I got the below error with sastrace on option.But it does not appear without sastrace option.
ERROR: This SQL statement will not be passed to the DBMS for processing because it involves a join across librefs with different connection properties.
To avoid this error,I tried to pull data from oracle tables into sas datasets and then merge but it's taking much more time than joining these two db tables in a single inner join query.Please suggest.Thanks.
If you read the note carefully, you'll see that recommend you to re-write your query to exploit explicit SQL pass-thru.
So you need to use Oracle specific syntax to join between the databases.
Thanks for the reply karl.But as I said in my first post,its taking less time (30 mins) when joining two librefs in single proc sql query.Whereas,while trying to pull data seperately from each database is taking longer than 2hrs.
So I am wondering,how can joining two librefs be inefficient when its taking less time. Since it throws an error with sastrace ON option,its not a showstopper for my coding.Just trying to get more info on this error.
Its really not an error as much as a warning. If you were access large datasets across librefs and using sas functions that did not translate to the dbms, sas would pull all of the data down from both tables before processing the query.
If you read the note carefully, you'll see that recommend you to re-write your query to exploit explicit SQL pass-thru.
So you need to use Oracle specific syntax to join between the databases.
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Select SAS Training centers are offering in-person courses. View upcoming courses for: