Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
mkjit256
Advocate II
Advocate II

Oracle Datasource Error - ORA-01652: unable to extend temp segment by 128 in tablespace temp

Hello,

I am connecting to two oracle DBs from the same pbix file. In power query, my first query has something as:

 

let
	Source = Oracle.Database("db1.world", [HierarchicalNavigation=true, CommandTimeout=#duration(0, 2, 0, 0)]),
    Schema = Source{[Schema="schema1"]}[Data],
    table1 = Schema{[Name="table1"]}[Data],
in
    table1

 

 My second query is similar to the first:

 

let
	Source = Oracle.Database("db2.world", [HierarchicalNavigation=true, CommandTimeout=#duration(0, 2, 0, 0)]),
    Schema = Source{[Schema="schema2"]}[Data],
    table2 = Schema{[Name="table2"]}[Data],
in
    table2

 

 

I am referencing these two tables (let's call them Primary tables) to create 4 other queries, (2 based on the first table (A1,B1) and the others based on the two tables, A2,B2). Let's call these secondary tables. 

 Finally i am appending the two queries A1,A2 together and B1,B2 together. 

 

In power query i have no problem with the process, however when i try to apply and close the steps, at some point i get an Oracle Datasource Error - ORA-01652: unable to extend temp segment by 128 in tablespace temp error. The only post that i had found suggested to contact the DBA to either increase the temp table, or to see why the database ran out of space. I tried with the DBA to check what was happening by monitoring the DB, but at that time, the problem didn't happen. Now the problem is occuring again, and the DBA is asking if there is a way to capture what SQL statement is being send from power query to the DB.

 

Any suggestion on why i am having this error or how can i capture the sql statemetns being send from power query to DB?

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @mkjit256 

Based on the error message, Oracle hasn't enough space to store intermediate data , you may need to check the block size, you can refer to the following link.

sql - ORA-01652: unable to extend temp segment by 128 in tablespace SYSTEM: How to extend? - Stack O...

And you can refer to the following link abut monitor the sql statement.

ORACLE-BASE - Real-Time SQL Monitoring (DBMS_SQLTUNE.REPORT_SQL_MONITOR)

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi @mkjit256 

Based on the error message, Oracle hasn't enough space to store intermediate data , you may need to check the block size, you can refer to the following link.

sql - ORA-01652: unable to extend temp segment by 128 in tablespace SYSTEM: How to extend? - Stack O...

And you can refer to the following link abut monitor the sql statement.

ORACLE-BASE - Real-Time SQL Monitoring (DBMS_SQLTUNE.REPORT_SQL_MONITOR)

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks for your reply. i have one question, when i am loading the two oracle query to power query and then doing some transformations and then appending the two into one, shouldn't that be handled by the Power Query Engine. Not sure why after extraction, the data is being processed in Oracle again? did i misunderstand something?

Thanks

Anonymous
Not applicable

Hi @mkjit256 

Based on the error message, Oracle hasn't enough space to store intermediate data , you may need to check the block size, you can refer to the following link.

sql - ORA-01652: unable to extend temp segment by 128 in tablespace SYSTEM: How to extend? - Stack O...

And you can refer to the following link abut monitor the sql statement.

ORACLE-BASE - Real-Time SQL Monitoring (DBMS_SQLTUNE.REPORT_SQL_MONITOR)

 

Best Regards!

Yolo Zhu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors