My PostgreSQL database contains a table My_Table featuring (among others) a column "entry_created_on" as date, and a column "entry_created_by" as text.
The default value of "entry_created_on" is: now() and the default value of "entry_created_by" is: "current_user"()
I use OpenOfficeBase (similar to MsAccess) as a front-end to populate the database through the JDBC driver. One of these forms deals with My_Table. I left out of the form any reference to "entry_created_on" and "entry_created_by", with the impression that the postmaster would provide those columns with their default values whenever a new entry was added to the table---which is exactly what I would like to see happening.
Instead, OOoBase throws the follow error message: "Error writing data to database. Input required in field 'entry_created_on'. Please enter a value."
On the other hand, everything works fine when I created a new row through an sql INSERT command, or through pgAdmin: I get the expected defaults values of now() and "current_user"().
Is the problem with the JDBC driver or is it with OOoBase? Does a similar situation occur with MsAccess? Have I forgotten something obvious?
PS: I tried using the SDBC driver, but OOoBase doesn't see the content of my tables, only their structure and the number of rows. I also tried with the ODBC driver, but I was even less successful, since I couldn't even see my schemas and tables, even though the driver claims to connect properly...
PPS: I was undecided where to send this; sorry if this issue was more appropriate to the Interface list!