Null Value in Power Table during Edit

Hello,

I have a database that I have in a power table with editing on a column enabled. This specific column can accept NULL values in the database. I can’t seem to get this behavior during an edit. For example, if I clear the field out, it forces me to enter a value. I’ve set the number format to “#” for testing purposes - but I am still required to enter a value.

Does anyone know how I can permit my users to set values to database NULL in a power table column w/editable enabled?

Thanks,

Brian

Wait until we implement that feature? :smiley:

We have a ticket for it, it's on the radar for "soonish", but I really don't know how soon that will be. If you want to be notified when it's been done, contact support and have them link you up with the ticket.

Will do - thank you!

Has there been any progress on this? Currently dealing with this issue, thanks!

Waiting as well…

Why not make the cell type a string?

In your onCellEdit, do something like

	val = None
	if newValue == None or newValue == "":
		val = 'Null'
	else:
		val = int(newValue)
	query = """ update [table] set [value] = %s """ % val
1 Like

I could sure use this function.

Tech genius Alejandro taught me a work around.
Using the Scripting Extension Function onPopupTrigger, type in the following script.
#NULL Entry Popup - Right Click will display Null Popup, Click to Enter Null Value
def setToNull(evt, cellValue=value):
ndx = self.data.getValueAt(rowIndex,0)
query = “UPDATE vdk SET %s = NULL WHERE ndx = ?” % colName
system.db.runPrepUpdate(query, [ndx])

menu = system.gui.createPopupMenu({'Clear':setToNull})
menu.show(event)

Work great. Thanks for all the help.

1 Like

Still waiting for this feature to be implemented.

Any Feature? XD

Somewhere in the last six years we’ve lost the ticket Kathy mentioned, or at least I can’t find it.

In any event, we’re obviously not treating this as a high priority issue. I would encourage going with the scripting workaround(s) mentioned higher in this thread.

all good. was just wondering hence the XD face. I did use the workaround and works perfect.

1 Like