Skip to content

Commit

Permalink
feat(hbi_utils.py): since most of tables are made private, need to ch…
Browse files Browse the repository at this point in the history
…ange the way of accessing them.
  • Loading branch information
Rajaditya Chauhan authored and jhutar committed Nov 8, 2024
1 parent 122bb3a commit dd7a4fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions opl/hbi_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def wait_for_next_second():

def fetch_records_count(inventory):
inventory_cursor = inventory.cursor()
inventory_cursor.execute("select count(*) as exact_count from hosts")
inventory_cursor.execute("select count(*) as exact_count from hbi.hosts")
for i in inventory_cursor.fetchone():
existing_records = int(i)

Expand Down Expand Up @@ -306,7 +306,7 @@ def cleanup(args, status_data):
inventory_cursor = inventory.cursor()

logging.info("Truncating Inventory DB 'hosts' table")
inventory_cursor.execute("TRUNCATE hosts CASCADE")
inventory_cursor.execute("TRUNCATE hbi.hosts CASCADE")
inventory.commit()

status_data.set_now("parameters.inventory_db.table_hosts.truncated_at")
Expand Down

0 comments on commit dd7a4fb

Please sign in to comment.