> Thanks to those who responded. However, this thread is going away from > what I really asked... not how to quote a string, but to confirm > whether or not SQLite had any idiosyncrasies related to string-quoting > other than the normal "escape single-quotes within the string."
You're doing it the hard way. if you bind program variables to parameters in the sql instead of building sql with literal data strings then you don't have to escape quotes at all. The sql interpreter never looks at them and they don't have to be quoted.