# PHP/MySQL - checking against field values

**URL:** <https://forum.kirupa.com/t/php-mysql-checking-against-field-values/205146>\
**Category:** programming\
**Created:** [October 26, 2006, 3:29pm UTC](https://forum.kirupa.com/t/php-mysql-checking-against-field-values/205146 "2006-10-26T15:29:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![robmcfeters](https://avatars.discourse-cdn.com/v4/letter/r/e36b37/32.png) [@robmcfeters](https://forum.kirupa.com/u/robmcfeters)\
**Post date:** [October 26, 2006, 3:29pm UTC](https://forum.kirupa.com/t/php-mysql-checking-against-field-values/205146/1 "2006-10-26T15:29:19Z")

</div>

I need some help.

The script I’m working on queries a table in MySQL. It will have say field A, B & C. I need to run through the entire column of field C, and gather the values of each row.

I need to do this so I can prevent a duplicate value from being added to that column.

How can I output that array to check against a value that is being posted?

Thanks
