﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
11165	Data gets truncated when saved	neoel	nobody	"I am working on a system to index my music library, and I think I stumbled on a bug.
When a query gets formed quote marks are not entered in the query. here is a piece of code where I believe the problem lies.
Below is the complete code.

The query is formed with this code:
   INSERT INTO `shoutcast_song` (`path`, `title`) VALUES (%s, %s)
the data is entered at the values but no quotation marks are found. 
I believe the code should be like this:
   INSERT INTO `shoutcast_song` (`path`, `title`) VALUES ('%s', '%s')


/var/lib/python-support/python2.5/django/db/models/sql/query.py in execute_sql

1727. except EmptyResultSet:
1728. if result_type == MULTI:
1729. return empty_iter()
1730. else:
1731. return
1732.
1733. cursor = self.connection.cursor()

1734. cursor.execute(sql, params) ...

1735.
1736. if not result_type:
1737. return cursor
1738. if result_type == SINGLE:
1739. if self.ordering_aliases:
1740. return cursor.fetchone()[:-len(results.ordering_aliases)]

▼ Local vars
Variable 	Value
cursor 	
<django.db.backends.util.CursorDebugWrapper object at 0x99fb2ac>
params 	
(""/files/Music/Q/Queens of the Stone Age - Songs For The Deaf/Queens Of The Stone Age - Era Vulgaris/Queens of the Stone Age - Queens Of The Stone Age/Queens of the Stone Age - Lullabies To Paralyze/Queens Of The Stone Age/Queens Of The Stone Age - Rated R/Queens Of The Stone Age - Songs For The Deaf [Europe]Queens Of The Stone Age - 01 - You Think I Ain't Worth A Dollar, But I Feel Like A Millionaire.mp3"", ""Queens Of The Stone Age - 01 - You Think I Ain't Worth A Dollar, But I Feel Like A Millionaire.mp3"")
result_type 	
None
self 	
<django.db.models.sql.subqueries.InsertQuery object at 0x99fb18c>
sql 	
'INSERT INTO `shoutcast_song` (`path`, `title`) VALUES (%s, %s)'"		closed	Uncategorized	1.0		invalid			Unreviewed	0	0	0	0	0	0
