Trying to work around undefined datatype problem