From owner-freebsd-python@freebsd.org  Thu Jan 26 18:25:41 2017
Return-Path: <owner-freebsd-python@freebsd.org>
Delivered-To: freebsd-python@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4720CCC33D8
 for <freebsd-python@mailman.ysv.freebsd.org>;
 Thu, 26 Jan 2017 18:25:41 +0000 (UTC)
 (envelope-from doug@safeport.com)
Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org
 [IPv6:2001:1900:2254:206a::50:5])
 by mx1.freebsd.org (Postfix) with ESMTP id 35C5A7F5
 for <freebsd-python@freebsd.org>; Thu, 26 Jan 2017 18:25:41 +0000 (UTC)
 (envelope-from doug@safeport.com)
Received: by mailman.ysv.freebsd.org (Postfix)
 id 3230DCC33D6; Thu, 26 Jan 2017 18:25:41 +0000 (UTC)
Delivered-To: python@mailman.ysv.freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org
 [IPv6:2001:1900:2254:206a::19:1])
 by mailman.ysv.freebsd.org (Postfix) with ESMTP id 31DAACC33D5
 for <python@mailman.ysv.freebsd.org>; Thu, 26 Jan 2017 18:25:41 +0000 (UTC)
 (envelope-from doug@safeport.com)
Received: from bucksport.safeport.com (bucksport.safeport.com [198.74.231.101])
 (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))
 (Client did not present a certificate)
 by mx1.freebsd.org (Postfix) with ESMTPS id E20547F1
 for <python@FreeBSD.org>; Thu, 26 Jan 2017 18:25:40 +0000 (UTC)
 (envelope-from doug@safeport.com)
Received: from bucksport.safeport.com (bucksport.safeport.com [198.74.231.101])
 by bucksport.safeport.com (8.14.5/8.14.5) with ESMTP id v0QINuhL045106
 for <python@FreeBSD.org>; Thu, 26 Jan 2017 13:23:56 -0500 (EST)
 (envelope-from doug@safeport.com)
Date: Thu, 26 Jan 2017 13:23:56 -0500 (EST)
From: DTD <doug@safeport.com>
To: python@FreeBSD.org
Subject: MySQLdb question
Message-ID: <alpine.BSF.2.00.1701261321410.15335@bucksport.safeport.com>
User-Agent: Alpine 2.00 (BSF 1167 2008-08-23)
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII
X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3
 (bucksport.safeport.com [198.74.231.101]);
 Thu, 26 Jan 2017 13:23:56 -0500 (EST)
X-BeenThere: freebsd-python@freebsd.org
X-Mailman-Version: 2.1.23
Precedence: list
List-Id: FreeBSD-specific Python issues <freebsd-python.freebsd.org>
List-Unsubscribe: <https://lists.freebsd.org/mailman/options/freebsd-python>, 
 <mailto:freebsd-python-request@freebsd.org?subject=unsubscribe>
List-Archive: <http://lists.freebsd.org/pipermail/freebsd-python/>
List-Post: <mailto:freebsd-python@freebsd.org>
List-Help: <mailto:freebsd-python-request@freebsd.org?subject=help>
List-Subscribe: <https://lists.freebsd.org/mailman/listinfo/freebsd-python>,
 <mailto:freebsd-python-request@freebsd.org?subject=subscribe>
X-List-Received-Date: Thu, 26 Jan 2017 18:25:41 -0000

I am using py27-MySQLdb-1.2.5 (the default) for FreeBSD 10.3

   cmd="update ipv4 set s8='%s',s16='%s',s24='%s' where ip='%s'" % (s8,s16,s24,row[0])
   c.execute(cmd)

does not work. I actually used try/except. It does not throw an error

   cmd=update ipv4 set s8='1.',s16='1.186.',s24='1.186.248.' where ip='1.186.248.251'

is a valid statement and works. It just does not work through execute. I also 
tried appending a ';' to cmd

Thanks for any help/thoughts

_____
Douglas Denault
http://www.safeport.com
doug@safeport.com
Voice: 301-217-9220
   Fax: 301-217-9277