Created
March 30, 2017 22:03
-
-
Save wongster80/77ccee824bef558d31f6678f6a0b5107 to your computer and use it in GitHub Desktop.
AbstractJsonArrayUnnestFactory - modified for long varchar
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class AbstractJsonArrayUnnestFactory : public TransformFunctionFactory { | |
public: | |
virtual void getPrototype(Vertica::ServerInterface &, | |
Vertica::ColumnTypes &argTypes, | |
Vertica::ColumnTypes &resTypes) | |
{ | |
//argTypes.addVarchar(); | |
//resTypes.addVarchar(); | |
argTypes.addLongVarchar(); /* Adding long varchar data type */ | |
resTypes.addLongVarchar(); | |
} | |
virtual void getReturnType(Vertica::ServerInterface &, | |
const Vertica::SizedColumnTypes &argTypes, | |
Vertica::SizedColumnTypes &resTypes) | |
{ | |
const Vertica::VerticaType &jsonSrcType = argTypes.getColumnType(0); | |
//resTypes.addVarchar(jsonSrcType.getStringLength(), T::resultColumnName()); | |
resTypes.addLongVarchar(jsonSrcType.getStringLength(), T::resultColumnName()); /* Adding long varchar data type */ | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment