ars_CreateEntry(ctrl, schema, field_id1, value1, ...)

This function creates a new entry (row) in the schema. This is the same as ``submitting a new ticket''. Pairs of field ids and values should follow the schema name. Data types are automatically converted.
On success
Returns the new entry id.
On failure
Returns undef.

Example 1:

 ($entry_id = ars_CreateEntry($c, "Schema01", $id, $val)) || 
die $ars_errstr;

Example 2:

  my %fieldname_to_id = ars_GetFieldTable($c, "User") || 
die $ars_errstr;
my $entry_id = ars_CreateEntry($c, "User",
$fieldname_to_id{"Login Name"}, "johnd",
$fieldname_to_id{"Full Name"}, "John Doe",
$fieldname_to_id{"Password"}, "xyz",
) || die $ars_errstr;

<-- Back to Table of Contents

Last changes to this page 13th August 2007 by Michiel Beijen
© J.C.Murphy, J.W.Murphy 1997 arsperl@arsperl.org