Not an if, but a similar thing is possible:
$product_option_value_data[] = array(
'product_option_value_id' => $product_option_value['product_option_value_id'],
'smallimage' => (isset($product_option_value_description_query->row['smallimage'])) ?
$product_option_value_description_query->row['smallimage'] : null,
'name' => $product_option_value_description_query->row['name'],
'price' => $product_option_value['price'],
'prefix' => $product_option_value['prefix']
);
Syntax:
(<statement> ? <case: true> : <case: false>)
(1 == 1 ? 'yes!' : 'PHP is wrong')