is there a way to use PHP+PDO to query a MySQL database and find out the column widths of some VARCHAR fields? I don't want to hardcode them into my PHP file if possible.
(purpose: determine maximum lengths of strings to be either inserted into these columns, or compared against existing data in the columns.)