BookmarkSubscribeRSS Feed
Halaku
Obsidian | Level 7
I need to find a method to truncate bunch of tables in Oracle. Is there a transformation available to do that?

Thanks,

MI
4 REPLIES 4
LinusH
Tourmaline | Level 20
If you are looking for a single transformation that truncates many tables, there is none.
I suggest that you crate a User Written Transformation to do this, which is quite simple (I have done one for SPD Server once). Use macro lopping over the input tables to the transformation which you would like to truncate

/Linus
Data never sleeps
Patrick
Opal | Level 21
Hi Linus
Agree with Oracle. With SPDS the table loader in DIS4.2 actually allows truncation so one could also implement this using a loop.
nar_sas
SAS Employee
The general table loader also supports the truncate behavior in 4.2 for most databases. You can also try that approach, and the Loop idea is a good suggestion to manage this for multiple tables.
Halaku
Obsidian | Level 7
Thanks folks for the reply.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to connect to databases in SAS Viya

Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 4 replies
  • 1363 views
  • 0 likes
  • 4 in conversation