OceanBase
English日本語简体中文
Docs Home
Products
Integrations
Release Notes

Databases

OceanBase DatabaseOceanBase Cloud OceanBase Best Practices

Tools

OceanBase Cloud PlatformOceanBase Migration ServiceOceanBase Developer CenterOceanBase Migration AssessmentOceanBase Admin ToolOceanBase Loader and DumperOceanBase DeployerKubernetes operator for OceanBaseOceanBase Diagnostic Tool OceanBase Binlog Service

Connectors and Middleware

OceanBase Database Proxy OceanBase Connector/C OceanBase Connector/J OceanBase Connector/ODBC OceanBase Connector/NETOceanBase Command-Line Client

Databases

OceanBase DatabaseOceanBase Cloud OceanBase Best Practices

Connectors and Middleware

OceanBase Database Proxy OceanBase Connector/C OceanBase Connector/J OceanBase Connector/ODBC OceanBase Connector/NETOceanBase Command-Line Client

Tools

OceanBase Cloud PlatformOceanBase Migration ServiceOceanBase Developer CenterOceanBase Migration AssessmentOceanBase Admin ToolOceanBase Loader and DumperOceanBase DeployerKubernetes operator for OceanBaseOceanBase Diagnostic Tool OceanBase Binlog Service
OceanBase DatabaseOceanBase Cloud ToolsConnectors and MiddlewareLifecycle Support Policy

OceanBase Connector/NET

V1.0.0
  • What Is OceanBase Connector/NET
    • Introduction
  • Install and Connect
    • Installation process
    • Test the connection
    • Reference a NuGet package
  • User Guide
    • Quick Start
      • Complete example
    • Connection Strings and Data Source
      • Connection strings
    • Data Types
      • Overview of data types
    • Command and Parameter
      • Overview
    • Result Set
      • Supported result set types
  • Reference Information
    • Common Interfaces
      • Overview of commonly used interfaces
  • Version Release Records
    • OceanBase Connector/NET V1.0.0

Download PDF

Document Feedback
  1. Documentation Center
  2. OceanBase Connector/NET
  3. V1.0.0

Reference a NuGet package

Last Updated:2026-09-04 08:24:51

Reference a NuGet package
Configure a local package source
Method 1: Specify the package source by using the command line (Recommended)
Method 2: Configure the nuget.config file

You can reference the NuGet package of OceanBase Connector/NET in the following ways:

Reference a NuGet package

If you can find the package in the default NuGet source, you can directly add the package reference to the project file (.csproj):

<ItemGroup>
  <PackageReference Include="Oceanbase.ManagedDataAccess" Version="1.0.0" />
</ItemGroup>

Configure a local package source

If you build the package locally, the default NuGet source cannot locate it. You need to configure the local package source.

Method 1: Specify the package source by using the command line (Recommended)

When you run the dotnet add command, specify the package source by using the --source option:

dotnet add <your project.csproj> package Oceanbase.ManagedDataAccess --version 1.0.0 --source "<package repository>" --source "https://api.nuget.org/v3/index.json"

Note

If you use the official NuGet source, retain --source "https://api.nuget.org/v3/index.json".

Method 2: Configure the nuget.config file

Create a nuget.config file in the project directory and add the local package source:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <add key="local-oceanbase" value="<package path>/packages" />
    <add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
  </packageSources>
</configuration>

After the configuration is completed, you can add the package reference to the project and resolve it from the local source.

Previous topic

Test the connection
Last

Next topic

Complete example
Next
on this page
Reference a NuGet package
Configure a local package source
Method 1: Specify the package source by using the command line (Recommended)
Method 2: Configure the nuget.config file