Change column data type based on value of another column possibble?

This if/else block below explains it better than I can with words…

if( 'project_media_type' === 'animated_gif'){
    image_url = JSON data type with image_url.gif_url, image_url.cover_img_url
}else{
    image_url = image URL data type
}

column project_media_type pulls a random value from a data set

if that value is animated_gif

then make the column image_url be a JSON data type

if the value is not animated_gif, then make the column image_url be a regular image url data type.

Is this possibble?

You could add the following inline formula to your image_url field:

if project_media_type == 'animated_gif'
 { gif_url: this, cover_img_url: 'cover.gif' }
else
 this
end