Uploading A File Via A Model But Not Save To Database? Is This Possible

Hi there, first thanks for taking the time to read and if possible help me with this.

I am relatively new to yii but I have to admit I am loving it and I have managed to do a lot with it so far, but im stuck on something and need some help.

what I need to know is there a way to add a file(s) upload to a model form, that will upload the file(s) but NOT store the data for the upload field(s) into the database?

I have it working now but ONLY if I add the file field to the database, which is something I do not want. I want the other fields added to the database but NOT the file upload fields.

for example my form has the following user inputs

title (what the user wants the uploaded file to be called)

category (the category id the user wants the file to be in)

ringtone_file(the file to be uploaded)

Now when the form is uploaded I do the following when all validation is complete

1, save the details of the form to the database

2, rename uploaded file to the "id" of the database entry for this model and move the ringtone_file to correct folder

however I do not need the field in the database for "ringtone_file" but I cannot get it to save to the database unless this field is added?

so can anyone help me out and tell me how I can add a file upload to a model form WITHOUT having to save the file details to the database.

I hope I have explained it ok but if not please feel free to ask questions.

and thank you for the help

regards

wayne

Could you not just remove the field in the database?

that was my first thought, but it turns out that if I dont have the "ringtone_file" column in the database table it will not save the record. I could get around it by just adding the columns in the tables but its extra bloat on the tables that I do not want, especialy when you have 125,000+ rows in those tables.

but thanks for suggesting

ok this is strange as I have just tried it again by removing the "ringtone_file" column from the table and the upload worked great!!!

so it would appear that I messed up somewhere else earlier in my code and I must have solved it and not realised?

oh well back to work then :)

regards

wayne