Skip to content

Commit f63fa6e

Browse files
author
mvazquez
committed
Added locked users query
1 parent 61ee2c5 commit f63fa6e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

pyora.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -454,6 +454,14 @@ def fra_use(self):
454454
for i in res:
455455
print i[0]
456456

457+
def locked_users(self):
458+
'''Query the locked users on the instance'''
459+
sql = "SELECT username FROM dba_users WHERE account_status != 'OPEN'"
460+
self.cur.execute(sql)
461+
res = self.cur.fetchall()
462+
for i in res:
463+
print i[0]
464+
457465
class Main(Checks):
458466
def __init__(self):
459467
parser = argparse.ArgumentParser()

0 commit comments

Comments
 (0)