COUNT Query Not Working

I am trying to get a count of the number of rows in a MS SQL database through a script query. I have a Popup Calendar object and when the user selects the date, it will check to see if that week is in the database (count > 0), if it isn’t then a new record will be created. The query I have works in the database query browser, but returns an error when I try to run it. There will be a variable in place for the date to select once the code is completed. The script is in the propertyChange of the Popup Calendar object.

[code]if event.propertyName == “date”:
dayOfWeek = system.db.dateFormat(event.newValue, “E”)
weekStart = system.db.dateFormat(event.newValue, “YYYY-MM-DD”)

# Message If Sunday Not Selected
if dayOfWeek <> "Sun":
	system.gui.messageBox("Please Select A Sunday")
	event.source.date = event.oldValue
# Process If Sunday Selected
if dayOfWeek == "Sun":
	# Check if database date range exists
	weekExistQuery = "SELECT COUNT (*) AS numRows FROM tblProdSchData WHERE WeekStart = '2015-01-04'"
	numRows = system.db.runUpdateQuery(weekExistQuery)
	print "Rows:",numRows[/code]

The error message I am receiving is:
Traceback (most recent call last):

File “event:propertyChange”, line 13, in

java.lang.Exception: java.lang.Exception: Error executing system.db.runUpdateQuery(SELECT COUNT (*) AS numRows FROM tblProdSchData WHERE WeekStart = ‘2015-01-04’, , , false)

caused by Exception: Error executing system.db.runUpdateQuery(SELECT COUNT (*) AS numRows FROM tblProdSchData WHERE WeekStart = '2015-01-04', , , false)
caused by GatewayException: SQL error for "SELECT COUNT (*) AS numRows FROM tblProdSchData WHERE WeekStart = '2015-01-04'": A result set was generated for update.
caused by SQLServerException: A result set was generated for update.

Ignition v7.7.2 (b2014121709)
Java: Oracle Corporation 1.8.0_31

Why are you using runUpdateQuery?

I think the best option would be to use runScalarQuery