BookmarkSubscribeRSS Feed
s260m107
Calcite | Level 5

I want to update the target table with some values from another table.I tried using update transformation and table-loader,it didn't work.

 

My target table has a column note_type  with values 'GRAD' and 'note'.I want to update the column reason_code for only 'NOTE' from another worktable in sas di.Could anyone let me know please.

2 REPLIES 2
Community_Guide
SAS Moderator

Hello @s260m107,


Your question requires more details before experts can help. Can you revise your question to include more information? 

 

Review this checklist:

  • Specify a meaningful subject line for your topic.  Avoid generic subjects like "need help," "SAS query," or "urgent."
  • When appropriate, provide sample data in text or DATA step format.  See this article for one method you can use.
  • If you're encountering an error in SAS, include the SAS log or a screenshot of the error condition. Use the Photos button to include the image in your message.
    use_buttons.png
  • It also helps to include an example (table or picture) of the result that you're trying to achieve.

To edit your original message, select the "blue gear" icon at the top of the message and select Edit Message.  From there you can adjust the title and add more details to the body of the message.  Or, simply reply to this message with any additional information you can supply.

 

edit_post.png

SAS experts are eager to help -- help them by providing as much detail as you can.

 

This prewritten response was triggered for you by fellow SAS Support Communities member @PGStats

.
Patrick
Opal | Level 21

@s260m107 wrote:

I want to update the target table with some values from another table.I tried using update transformation and table-loader,it didn't work.

 

My target table has a column note_type  with values 'GRAD' and 'note'.I want to update the column reason_code for only 'NOTE' from another worktable in sas di.Could anyone let me know please.


 

DIS questions are best asked in the Data Management forum here

 

From what you describe the SQL Update transformation feels right.

 

"it didn't work" is very vague. Assuming this means the job run without errors but the target table did't get updated: Most likely code is that you either didn't set-up the transformation as you should or the data in the key column is not matching (eventually wrap an upcase(compress(note_type) around the column (for both source and target table column).

 

To investigate what's happening: Have a look into the generated SQL Update code. Does it look right? Else start changing the configuration for the SQL Update transformation until the generated SQL code looks right. Eventually post the generated code here.

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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
  • 2 replies
  • 491 views
  • 0 likes
  • 3 in conversation