How to call default node validation functions I have a custom node-creation form for which I have my own validation function. How can I make sure that after my validation function the form goes through the same validation that it would have done on the original node-creation form?
Some thing like node_validate looks like the kind of thing I need, but it works on $node objects rather than forms.
The order of operations I perceive to be the best is


On submit run custom validation
If custom validation passes run the normal node validation
If node validation succeeds insert values in the database


Is that a good and Drupal way?
If your form has a structure similar to the one used for the node edit form, then you can use node_validate(), which is called from the form validation handler for the node edit form.

function node_form_validate($form, &amp;$form_state) {
  node_validate($form_state['values'], $form);
}


node_validate() converts the first argument in an object using the following code.

  // Convert the node to an object, if necessary.
  $node = (object) $node;
  $type = node_get_types('type', $node);


Your form validation handler's code should be similar to the following one.

function mymodule_form_validate($form, &amp;$form_state) {
  // Run your validation code.
  node_validate($form_state['values'], $form);
}


As general rule, the validation code should go in the form validation handler. If the form validation handler set any error, the form submission handler is not called, and the user is returned to the form to correct what is wrong in the data that has been submitted.