Checking for uniqueness of fields even after one of the fields involved has failed validation

Created on 11 February 2011, almost 14 years ago
Updated 18 April 2024, 8 months ago

I've got a content type that uses a combination of 3 fields for its uniqueness check.
One of them is an integer field.

If you put letters in this integer field (called Project Number in this case) it fails validation and you get the following messages:

"Only numbers are allowed in Project Number"

"Could not formulate query for unique_field_match_value on field_project_number with data type int."

"Warning: array_intersect(): Argument #2 is not an array in unique_field_nodeapi() (line 209 of /var/www/sites/all/modules/unique_field/unique_field.module)."

I think this may be because unique field is testing the node uniqueness even after the node has failed to save due to the integer field having letters in it and as such there's a data type mismatch in the query involved.

πŸ› Bug report
Status

Closed: outdated

Version

1.4

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom Shadlington

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • πŸ‡ΊπŸ‡¦Ukraine AstonVictor

    I'm closing it because the issue was created a long time ago without any further steps.

    if you still need it then raise a new one.
    thanks

Production build 0.71.5 2024