SAS Programming

DATA Step, Macro, Functions and more
BookmarkSubscribeRSS Feed
sasuser77
Calcite | Level 5

Hi,

 

I want to know the efficient way to update Access 2007 table using sas. Currently I am trying to delete entire records based on a Key field and re-insert the data. 

 

Is there a alternate way to update data if there exists a key, otherwise insert to the table. I found below thread for SQL server, want to see how this can be implemented in Access.

 

https://communities.sas.com/t5/SAS-Procedures/Efficiently-updating-Sql-server-Table-using-SAS-Datase...

 

Venkat

3 REPLIES 3
Reeza
Super User

The difference here is that the is SQL Pass Through - the query is passed to the DB so it ends up using the DB SQL, not SAS SQL. Also, the work happens on the server directly which is faster. 

 

You don't have the flexibility with Access since it's also local so you won't see the same type of improvements. 

 

If you're connecting to the Access table, have you tried using an UPDATE or MODIFY statement instead?

LinusH
Tourmaline | Level 20
Do you have any performance issues?
Step 1 is to understand how to tune the Access update, and that part is probably best answered elsewhere. Then investigate how that soon to know method is accomplished by using SAS.
Data never sleeps

sas-innovate-white.png

Our biggest data and AI event of the year.

Don’t miss the livestream kicking off May 7. It’s free. It’s easy. And it’s the best seat in the house.

Join us virtually with our complimentary SAS Innovate Digital Pass. Watch live or on-demand in multiple languages, with translations available to help you get the most out of every session.

 

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 3 replies
  • 2245 views
  • 0 likes
  • 4 in conversation