BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
PravinMishra
Quartz | Level 8

Hi,

I have two SAS table  one and two.both the table having some same column and some different col.I need to append the data and create a single dataset. on top of that I need to create view on the combine table.

I am using below code but not able to do it.

data join / view=one.join_vw;

set one two;

run;

its throwing an error

ERROR: The requested type of view (Input or Output) cannot be determined.

let me know anyone have any solution for this.

further I need to access the view for different process. can I would be able to access the view as it is created on two different table.

Thanks;

1 ACCEPTED SOLUTION

Accepted Solutions
PravinMishra
Quartz | Level 8

I have used below code and it's working fine.

data join_one/view=join_one;

set oil.oil;

run;

data join_two/view=join_two;

set ocb.ocb;

run;

data out.join_vw/ view=out.join_vw;

set join_one join_two;

run;

data join_out;

set out.join_vw;

run;

View solution in original post

2 REPLIES 2
Haikuo
Onyx | Level 15

I think you syntax is a bit off,  you can only have ONE name for ONE view, here you are offering two: 'join' and 'one.join_vw'. Try to make them the same:

data one.join_vw / view=one.join_vw;

set one two;

run;

Good luck,

Haikuo

BTW, just to be clear, SAS View is a piece of SAS code, so it doesn't care how many tables involved, when you used it, it also doesn't care if it is sourced from multiple tables.

PravinMishra
Quartz | Level 8

I have used below code and it's working fine.

data join_one/view=join_one;

set oil.oil;

run;

data join_two/view=join_two;

set ocb.ocb;

run;

data out.join_vw/ view=out.join_vw;

set join_one join_two;

run;

data join_out;

set out.join_vw;

run;

hackathon24-white-horiz.png

The 2025 SAS Hackathon Kicks Off on June 11!

Watch the live Hackathon Kickoff to get all the essential information about the SAS Hackathon—including how to join, how to participate, and expert tips for success.

YouTube LinkedIn

Creating Custom Steps in SAS Studio

Check out this tutorial series to learn how to build your own steps in SAS Studio.

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