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

so i started using this macro a bit late.  howwever, i am getting syntax errors.  i am running this statement.

%mdsecds(memberfilter="@ID='A5HDAJSI.B90006Y5'");

any idea why?  i got the object id from the management console.  thanks.

NOTE 137-205: Line generated by the invoked macro "MDSECVW".
80         (location, objname, publictype, ObjId);           create view &targdata as          select &objcols, &trancols from
                                                                                                                          ____
5                                                          The SAS System                                14:26 Thursday, May 7, 2015

                                                                                                                          22
80       ! &trandata a inner join &objdata b on a.objuri=b.objuri             order by location, objname, publictype, objid,
80       ! identityname,
ERROR 22-322: Syntax error, expecting one of the following: a name, ;, (, ',', ANSIMISS, AS, CROSS, EXCEPT, FULL, GROUP, HAVING,
              INNER, INTERSECT, JOIN, LEFT, NATURAL, NOMISS, ORDER, OUTER, RIGHT, UNION, USING, WHERE. 

NOTE: Line generated by the invoked macro "MDSECVW".
80         (location, objname, publictype, ObjId);           create view &targdata as          select &objcols, &trancols from
                                                                                                                          ____
                                                                                                                          76
80       ! &trandata a inner join &objdata b on a.objuri=b.objuri             order by location, objname, publictype, objid,
80       ! identityname,
ERROR 76-322: Syntax error, statement will be ignored.

NOTE: Line generated by the macro variable "TRANCOLS".
80          a.identitydispname, a.identityname, a.identitytype, a.Administer, a.CheckInMetadata, a.Create, a.Delete, a.Read,
80       ! a.ReadMetadata, a.Write, a.WriteMemberMetadata, a.WriteMetadata, a.Alter Table, a.Create Table, a.Drop Table, a.Insert,
                                                                                    _____
                                                                                    22
80       ! a.Select, a.Update
ERROR 22-322: Syntax error, expecting one of the following: !, !!, &, *, **, +, ',', -, /, <, <=, <>, =, >, >=, ?, AND, AS,
              CONTAINS, EQ, EQT, FROM, GE, GET, GT, GTT, LE, LET, LIKE, LT, LTT, NE, NET, OR, ^=, |, ||, ~=. 

NOTE: PROC SQL set option NOEXEC and will continue to check the syntax of statements.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE SQL used (Total process time):
      real time           0.06 seconds
      cpu time            0.06 seconds

1 ACCEPTED SOLUTION

Accepted Solutions
DanielaNRW
Obsidian | Level 7

Hi,

this is really strange because the documentation shows the same sample code as your code.

The macro variables &objcols or &trancols might be empty, so the sql statement cannot be executed.

Have you tried to provide a path to start your search?

Daniela

View solution in original post

2 REPLIES 2
DanielaNRW
Obsidian | Level 7

Hi,

this is really strange because the documentation shows the same sample code as your code.

The macro variables &objcols or &trancols might be empty, so the sql statement cannot be executed.

Have you tried to provide a path to start your search?

Daniela

Grumbler
Obsidian | Level 7

thanks daniela.  i put specified the path to the object and it ran without any problem.

suga badge.PNGThe SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment. 

Join SUGA 

Get Started with SAS Information Catalog in SAS Viya

SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 1604 views
  • 1 like
  • 2 in conversation