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

hi all 

 

I am unable to figure out the erorr in this code. Any help is appreciated.

 

Thank You

NOTE: Remote submit to MYNODE complete.
43   rsubmit ;
NOTE: Remote submit to MYNODE commencing.
303  *union t table from medicare and medicad together ;
304  proc sql;
305
306      *commercial;
307
308      create table data._03_t_table as
309          select distinct a.*,b.dtstart,b.dtend
310          from data._01_claims as a
311          inner join original.ccaet141 as b
312          on a.enrolid =b.enrolid
313      union
314          select distinct c.*,d.dtstart,d.dtend
315          from data._01_claims as c
316          inner join original.ccaet151 as d
317          on c.enrolid =d.enrolid
318          order by c.enrolid,c.svcdate,c.prod_grp
319      ;
ERROR: Unresolved reference to table/correlation name c.
ERROR: Unresolved reference to table/correlation name c.
ERROR: Unresolved reference to table/correlation name c.
NOTE: PROC SQL set option NOEXEC and will continue to check the syntax of statements.
320  quit ;
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE SQL used (Total process time):
      real time           0.00 seconds
      cpu time            0.00 seconds

NOTE: Remote submit to MYNODE complete.
1 ACCEPTED SOLUTION

Accepted Solutions
SASKiwi
PROC Star

Try removing the C from your ORDER BY

 order by enrolid, svcdate, prod_grp

View solution in original post

1 REPLY 1
SASKiwi
PROC Star

Try removing the C from your ORDER BY

 order by enrolid, svcdate, prod_grp

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!

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.

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
  • 1 reply
  • 789 views
  • 4 likes
  • 2 in conversation