0
votes

In my job we use Python to make the ETL's.

So everything was fine until I had to insert BLOB values.

The logic we have is like this. We have a select from the database origin (also Oracle) and we save this data into a .csv file, then we read this file and with the help of SQLLoader we populate the table in the other database.

I can't do this with a BLOB file because when I try to make a

select <column1> || ',' || <column2> || ',' || <blob> 
from <table>

this statement fails because I can't concatenate the BLOB value.

So I tried making a insert line per line but it's too slow.

There is another way I can do this? I don't know if I can make an

insert into <table>
select <columns>
from <table_origin>

when I had two different databases. I hope you can help. Thanks for advanced.

1

1 Answers

0
votes

Concatenate in the python, not in the SQL, then you can just:

select <column1>, <column2>, <blob> from <table>