dotConnect for Oracle Documentation
Devart.Data.Oracle Namespace / OracleParameter Class / Value Property
Example

In This Topic
    Value Property (OracleParameter)
    In This Topic
    Gets or sets the value of the parameter.
    Syntax
    'Declaration
     
    Public Overrides Property Value As Object
    public override object Value {get; set;}

    Property Value

    An System.Object that is the value of the parameter. The default value is null.
    Remarks
    For input parameters, the value is bound to the OracleCommand that is sent to the server. For output and return-value parameters, the value is set on completion of the OracleCommand and after the OracleDataReader is closed.

    When sending a null parameter value to the server, the user must specify System.DBNull, not null. A null value in the system is an empty object that has no value. System.DBNull is used to represent null values.

    If the application specifies the database type, the bound value is converted to that type when the provider sends the data to the server. The provider attempts to convert any type of value if it supports the IConvertible interface. Conversion errors may result if the specified type is not compatible with the value.

    Both the DbType and OracleDbType properties can be inferred by setting Value. If applicable, the size, precision and scale will also be inferred from Value.

    The Value property is overwritten by the System.Data.Common.DbDataAdapter.Update() method.

    Example
    The following example creates a OracleParameter and sets some of its properties.
    public void CreateOracleParameter()
    {
      OracleParameter myParameter = new OracleParameter("DName", OracleDbType.VarChar, 15);
      myParameter.Value = "PRODUCTION";
    }
    Public Sub CreateOracleParameter()
      Dim myParameter As New OracleParameter("DName", OracleDbType.VarChar, 15)
      myParameter.Value = "PRODUCTION"
    End Sub 'CreatePgSqlParameter
    Requirements

    Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also