I am using python 3.10 on I64 with the Rdb package.
What i don't understand is why python cannot create temp files that are needed for Rdb.
Example:
Python program has to delete 10 records from a Rdb table that works fine.
Same program has to delete 10.00 records it always fails with this error.
What should I do to get this solved.
%RDB-F-SYS_REQUEST, error from system services requestd
-COSI-F-CREATERR, cannot create file
Code: Select all
Short Python code:
import requests
import time
import json
import re
import _rdb
import _decc
sqlca = _rdb.sqlca()
if sqlca.attach(source_database) != 0:
raise Exception("attach failed:\n" + sqlca.message)
print(time.strftime('%Y-%m-%d %H:%M:%S') + ": starting cleanup")
threshold_time = time.strftime('%Y-%m-%d %H:%M:%S', time.localtime(time.time() - expire_time))
print(f"threshold_time: {threshold_time}")
sqlca.set_readwrite()
query_str = f'''DELETE FROM DATA_TO_CLOUD
WHERE PROCESSING_STATUS = 'PROCESSED'
AND CREATED_AT < TIMESTAMP '{threshold_time}' '''
cleanup_query = sqlca.prepare(query_str)
if DEBUG:
print(query_str)
if cleanup_query == None:
raise Exception("cleanup failed:\n" + sqlca.message)
if cleanup_query.exec() == 0:
print("delete: ", sqlca.code, sqlca.message)
sqlca.commit()
else:
print("delete failed: ", sqlca.code, sqlca.message)
sqlca.rollback()
%RDB-F-SYS_REQUEST, error from system services requestd
-COSI-F-CREATERR, cannot create file