Hi, I have a string that I need to extract just the sql statement. The following is the string \000\000\000\000\000\000\000\000.\000\000\000\0000\000\000\000 \000$\000\000\000\000\000(\000\000\000\000X\000\000\000\000\000, \000\000\000\000P\000\000\000\000\000Q\000\000\000\000\000R\000 \000\000\000\000/\000\000\000�\000\000\000\000%����\000\000\000 \000'����\000\000\000\000+brttyp\000�\000\000\000\000*SELECT Brttyp.ctrscode, Brttyp.cdescript, Brttyp.ctrstype, Brttyp.cstatus, Brttyp.lreqno, Brttyp.dcreate FROM brttyp Brttyp WHERE Brttyp.ctrscode = ( ?gcKey1 )\000\000\000\000\000 AMCONNECT\000\000\000\000\000) \000\000\000\000\000\000\000 \000\000\000\000BR Transaction Code File\000
How can I get rid of all the junk? I can find the '*' with str.find('*') but I can't use find '\000' to get to the end? -- John Fabiani _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor