Home » Developer & Programmer » Forms » Create A New Record (Developer Suite Version 10.1.2.0.2 )
icon5.gif  Create A New Record [message #380978] Wed, 14 January 2009 09:55 Go to next message
Kevin58
Messages: 79
Registered: January 2009
Member
I have a simple form with two data blocks.
The first is tied to a database table.
The second is a "control" block without a database table.

I'm trying to create a new record. I am creating the primary key
from values entered on the form and checking the database for the next value based on two characters used to query the database.

The form creates the key just fine. However, I cannot save the
record with a commit_form statement. It says there is no changes to save.

Am I suppose to create my own insert statement to store
the "new" record?
Re: Create A New Record [message #381000 is a reply to message #380978] Wed, 14 January 2009 14:40 Go to previous messageGo to next message
Littlefoot
Messages: 21823
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Which block contains newly created key value? Is it a data block, or a control block? If "new record's" column values are prepared for insert in the control block, you'll have to manually INSERT these values into a table. If, on the other hand, this record is in a data block, try STANDARD.COMMIT instead of COMMIT_FORM.
Re: Create A New Record [message #381029 is a reply to message #380978] Wed, 14 January 2009 22:53 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Are the items into which you have placed the data defined as being database fields?

David
Re: Create A New Record [message #381187 is a reply to message #381029] Thu, 15 January 2009 10:16 Go to previous messageGo to next message
Kevin58
Messages: 79
Registered: January 2009
Member
djmartin wrote on Wed, 14 January 2009 22:53
Are the items into which you have placed the data defined as being database fields?

David

Hi David,

I think I've gotten it figured out. There were several issues.
One I was working on someone elses form. They had set the
Advanced Database DML Data Target Type from "Table to "None".
I set it back to "Table".

It is working as expected now. Thanks for helping! Smile
Re: Create A New Record [message #381224 is a reply to message #381187] Thu, 15 January 2009 21:30 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
You don't need to quote the whole of a post in a particular thread. We will have read it.

David
Re: Create A New Record [message #381323 is a reply to message #381224] Fri, 16 January 2009 06:16 Go to previous message
Kevin58
Messages: 79
Registered: January 2009
Member
OK. Thanks again for your help!
Previous Topic: Scrollbar for MLB didn't work as expected
Next Topic: ANSI Joins in Forms 6
Goto Forum:
  


Current Time: Tue Feb 18 11:01:28 CST 2025