Desktop productivity for business analysts and programmers

SAS EG Modify data in MSSQL data table

Reply
Contributor
Posts: 22

SAS EG Modify data in MSSQL data table

Hi there, i wonder if there is any practical way to update data in MSSQL through EG with direct modification on data value in a dataview.

I currently assigned a library referencing to MSSQL database and direct open the data in the library with data protect off to have direct modification on MSSQL data.

I wonder if there is any other method, please advice thanks
Super Contributor
Posts: 578

Re: SAS EG Modify data in MSSQL data table

You should be able to use the normal SAS update procedures like proc sql or data step modify.
Contributor
Posts: 22

Re: SAS EG Modify data in MSSQL data table

Yes, I know I could use SAS procedure SQL or data step to update. I am just asking for alternative with direct modification on data just by dataview. And i am asking if I am using the practical way to perform this? I just wndering if there is other way to do such purpose. Please advice thanks!
Super User
Posts: 5,386

Re: SAS EG Modify data in MSSQL data table

If you are limited to EG, I would say no.
We have also tried to use it to update data, and it doesn't work too well on all scenarios.
Is there are specific problem which makes you looking for an alternative?

/Linus
Data never sleeps
Contributor
Posts: 22

Re: SAS EG Modify data in MSSQL data table

well, actually updating via sas dataset can be the solution of my case for direct updating the data in MSSQL table. I am just trying figure out if there is any alternative only as i am a nobody in SAS environment and just want to have some feedback from you guys expert or experienced programmer in SAS. Thanks for your reply!
Super User
Posts: 5,386

Re: SAS EG Modify data in MSSQL data table

Updating via data viewer can work ok, but it's not ideal.
Things to consider:
-Avoid meta libanme
-Defaults constraints: it won't work, especially together with NOT NULL constraint.

/Linus
Data never sleeps
Ask a Question
Discussion stats
  • 5 replies
  • 158 views
  • 0 likes
  • 3 in conversation