sql - SAS Enterprise Guide: How to get Oracle table indexes -


i using sas enterprise guide (eg) 6.1 , want know indexes of our oracle tables. there way write program information?

i tried do:

libname dw oracle user='username' password='password' path='path.world' schema='schema';  data _null_ ; dsid = open(dw.some_table) ; isindexed = attrn(dsid,"isindex") ; put isindexed = ; run ; 

some_table name of (my table), error:

error: data step component object failure.  aborted during compilation phase. error 557-185: variable some_table not object. 

reference: https://communities.sas.com/t5/ods-and-base-reporting/check-if-index-exists/td-p/1966

open takes string or value resolves string. need

dsid= open('dw.some_dataset'); 

i don't know if can use oracle or not, , don't know whether attrn useful particular purpose or not. these work sas datasets, it's libname engine (and whatever middleware uses) implement functionality attrn use.

for example, don't use oracle have sql server tables indexes, , can run above code on them; code appears work (it doesn't show errors) shows tables being unindexed, when are.

your best bet connect using pass-through (connect ...) instead of libname, , can run native oracle syntax rather using sas.


Comments

Popular posts from this blog

networking - Vagrant-provisioned VirtualBox VM is not reachable from Ubuntu host -

c# - ASP.NET Core - There is already an object named 'AspNetRoles' in the database -

ruby on rails - ArgumentError: Missing host to link to! Please provide the :host parameter, set default_url_options[:host], or set :only_path to true -