writing database defined default values

I think it ought to be possible to have an extra choice in the dataprovider window when you open the properties. I would like to have the ability to auto enter the default values as they are defined in the database backend for a certain field.

In Postgres I can do this by sending this SQL statement:

INSERT INTO products (product_no, name, price) VALUES (1, ‘Cheese’, DEFAULT);

The problem I can’t solve right now is this:

  1. Postgresql backend fields are defined as NOT NULL DEFAULT ‘’ (empty string)
  2. This setup creates an error within Servoy (even when for these fields autoenter property is marked database managed)
  3. When I enter a record with not all values entered I get an error (Cannot save form data: field x cannot be null)

Big problem for me right now, so if anybody has a clue (besides working within a transaction and procedurally checking every field)

tia