The documentation is here: https://my.vertica.com/docs/6.1.x/HTML/index.htm#11722.htm
The last line of example code is clearly problematic, and cannot have been run.
command.Parameters["STATE"] = 'MA';2 obvious things are incorrect here:
- Single quotes are used to denote character literals in C# - see http://msdn.microsoft.com/en-us/library/aa691087(v=vs.71).aspx
- The signature for the indexer method of the VerticaParameterCollection class (the type of the object exposed by command.Parameters) specifies that a VerticaParameter object is returned (public new VerticaParameter this[string name] { get; set; }). Neither a string literal, nor a character literal, may be implicitly cast to a VerticaParameter. because of this, the code provided in the example will not compile, even if the character literal is corrected to be a string literal.