Inserting Image to oracle DB 11g

I want to insert images to oracle DB 11g, the table has a field Blob for images, i tried with insert with this code in views

< Blockquote
form = CarForm(request.POST)
if form.is_valid():
pho_matricule = form.cleaned_data.get(“pho_matricule”)
pho_date = form.cleaned_data.get(“pho_date”)
pho_employer= form.cleaned_data.get(“pho_employer”)
pho_photos = form.cleaned_data.get(“pho_photos”)
conn = connection()
cursor = conn.cursor()
cursor.execute(“INSERT INTO GRHM.h_photos VALUES (:pho_matricule :pho_date, :pho_employer, :pho_photos)”, [pho_matricule, pho_date,pho_employer,pho_photos])


But this wont work , could you please help

First, when posting code here, enclose the block of code between lines of three backtick - ` characters. This means you’ll have a line of ```, then your code, then another line of ```. This forces the forum software to keep your code properly formatted.

If you want specific help, we’ll also need to see the Model and the Form for this.

You should probably also read:

(Uploaded files are not just additional fields in the form, they require special handling.)