BookmarkSubscribeRSS Feed
mrainer
Calcite | Level 5

Hello!

I use the WITH statement in DB2 pass-thru sql to create a series temporary tables in order to get all the data I need for my pass-thru join. These tables are deleted when the query closes and are therefore not traditional temporary tables where I create from the SAS side and load with data from SAS. This query needs to be converted to Oracle as they are swapping out their old DB2 database. What is the equivalent Oracle syntax for the WITH statement in order to make a series of tables within my pass-through query that I can all join together while still in-database? I attached a sample of the code that I wrote for DB2 that needs the Oracle equivalent syntax.

Thank you!!

michael

1 REPLY 1
TomKari
Onyx | Level 15

Hi, mrainer

Looking at your request, I believe your question pertains completely to the SQL syntax for DB2. Based on this, I suggest that you pursue this with IBM and Oracle.

While SAS users connect to DB2 and Oracle, we aren't necessarily experts on the implications of the SQL dialects that they provide. I think that your best course of action is to get your query working in native Oracle, and then using it with SAS should be very straightforward.

Tom

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to Concatenate Values

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 1 reply
  • 588 views
  • 0 likes
  • 2 in conversation