On Dec 21, 9:11 am, SMALLp <[EMAIL PROTECTED]> wrote:
> Hy! I have error something like this
>
> TypeError: unbound method insert() must be called with insertData
> instance as first argument (got str instance instead)
>
> CODE:
>
> File1.py
> sql.insertData.insert("files", data)
>
> sql.py
>
> class insertData:
> def insert(self, dataTable, data):
> conn = self.openConnection.openConnection()
> cursor = conn.cursor()
> sql ="INSERT INTO "+dataTable+" (user_name, file_name,
> file_size,
> file_path_local, file_path_FTP, curent_location, FTP_valid_time,
> uploaded, last_modified, last_verified, file_type, file_category) VLAUES
> "+data
> cursor.execute(sql)
> conn.Close()
>
> Help and advice neaded!
I think you need to post the real traceback or the real code since
your error message doesn't look like it has anything to do with the
code above. At least, I do not see a method named "insert".
Which database module are you using?
Mike
--
http://mail.python.org/mailman/listinfo/python-list