- What versions are you using?
Oracle DB: 19.28.0.0.0
python: 3.12.9
python-oracledb: 3.4.2
- Is it an error or a hang or a crash?
- What error(s) or behavior you are seeing?
oracledb.exceptions.DatabaseError: DPY-4009: 2 positional bind values are required but 1 were provided
- Does your application call init_oracle_client()?
- Include a runnable Python script that shows the problem.
#!/usr/bin/env python3
import oracledb
conn = oracledb.connect()
rows = [
(1,),
(2,),
(3,),
]
conn.direct_path_load(
schema_name="test_schema",
table_name="test_issue",
column_names=["id"],
data=rows
)
The code works as expected with this table definition:
create table test_issue(
id number,
test_date date
)
The code throws the error with this table definition:
create table test_issue(
id number,
test_date date default sysdate
)
If I explicitly include a test_date value in the rows it works in both cases.