CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 insert doesn't work when key fields are hidden

Print topic Send  topic

Author Message
John Reitano
Posted: 04/18/2002, 9:48 AM

I'm using JSP with templates and I have a "Record" form that does inserts and updates.

When I show the key fields as TextBoxes, the form works, but when I make them hidden fields, it doesn't.

Any ideas on why this is so?
Markus
Posted: 04/18/2002, 10:59 AM

Although I don't use JSP with templates but with ASP with templates, I found that when you set the keyfield to 'required' that this prevents Insert from working. The keyfield was defined as autonumber and this does not coorperate with the code generated for 'required' field.
Nicole
Posted: 04/19/2002, 12:21 AM

John,
CC expects primary key to be auto increment. Then on Record form it should be marked as 'Key' field and defined as 'Hidden'. Check it.
In case key field isn't autonumber you should assign any value to it before inserting to db. Thus if you do not want it to be textbox you should create Custom Action event and include it into sql query.

Markus,
Input parameters on Record form are different to Grid Input parameters. If input parameter is marked as 'Required' it will be included into insert and update sql statement. Of course once the same field is already present on the form it will be included twice into sql statement.

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.