-
Notifications
You must be signed in to change notification settings - Fork 96
Closed
Labels
Description
- Describe your new request in detail
python-oracledb internally parses the content of the tnsnames.ora file here but does not provide or expose a way to list the available service names parsed.
We have use cases where we need to switch between database services. It would be logical to propose the list of available services from the list of services parsed by python-oracledb.
Something like below or similar would work:
from oracledb.connect_params import ConnectParams
params = ConnectParamsImpl()
service_names = params.available_service_names()
# do something with service_names
print(service_names)Is that something feasible? What are your thoughts?
- Give supporting information about tools and operating systems. Give relevant product version numbers
import oracledb
import sys
import platform
print("oracledb.__version__:", oracledb.__version__)
print("platform.platform:", platform.platform())
print("sys.maxsize > 2**32:", sys.maxsize > 2**32)
print("platform.python_version:", platform.python_version())oracledb.__version__: 2.1.0
platform.platform: Windows-10-10.0.19044-SP0
sys.maxsize > 2**32: True
platform.python_version: 3.11.5