Files
FreeSql/api/FreeSql.FreeSqlBuilder.html
2023-07-07 17:27:43 +00:00

1049 lines
47 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<!--[if IE]><![endif]-->
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Class FreeSqlBuilder
| FreeSql API Docs </title>
<meta name="viewport" content="width=device-width">
<meta name="title" content="Class FreeSqlBuilder
| FreeSql API Docs ">
<meta name="generator" content="docfx 2.59.4.0">
<link rel="shortcut icon" href="../favicon.ico">
<link rel="stylesheet" href="../styles/docfx.vendor.css">
<link rel="stylesheet" href="../styles/docfx.css">
<link rel="stylesheet" href="../styles/main.css">
<meta property="docfx:navrel" content="../toc.html">
<meta property="docfx:tocrel" content="toc.html">
<meta property="docfx:rel" content="../">
</head>
<body data-spy="scroll" data-target="#affix" data-offset="120">
<div id="wrapper">
<header>
<nav id="autocollapse" class="navbar navbar-inverse ng-scope" role="navigation">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="../index.html">
<img id="logo" class="svg" src=".././images/logo.svg" alt="">
</a>
</div>
<div class="collapse navbar-collapse" id="navbar">
<form class="navbar-form navbar-right" role="search" id="search">
<div class="form-group">
<input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off">
</div>
</form>
</div>
</div>
</nav>
<div class="subnav navbar navbar-default">
<div class="container hide-when-search" id="breadcrumb">
<ul class="breadcrumb">
<li></li>
</ul>
</div>
</div>
</header>
<div class="container body-content">
<div id="search-results">
<div class="search-list">Search Results for <span></span></div>
<div class="sr-items">
<p><i class="glyphicon glyphicon-refresh index-loading"></i></p>
</div>
<ul id="pagination" data-first="First" data-prev="Previous" data-next="Next" data-last="Last"></ul>
</div>
</div>
<div role="main" class="container body-content hide-when-search">
<div class="sidenav hide-when-search">
<a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a>
<div class="sidetoggle collapse" id="sidetoggle">
<div id="sidetoc"></div>
</div>
</div>
<div class="article row grid-right">
<div class="col-md-10">
<article class="content wrap" id="_content" data-uid="FreeSql.FreeSqlBuilder">
<h1 id="FreeSql_FreeSqlBuilder" data-uid="FreeSql.FreeSqlBuilder" class="text-break">Class FreeSqlBuilder
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>
<div class="inheritance">
<h5>Inheritance</h5>
<div class="level0"><span class="xref">System.Object</span></div>
<div class="level1"><span class="xref">FreeSqlBuilder</span></div>
</div>
<div class="inheritedMembers">
<h5>Inherited Members</h5>
<div>
<span class="xref">System.Object.Equals(System.Object)</span>
</div>
<div>
<span class="xref">System.Object.Equals(System.Object, System.Object)</span>
</div>
<div>
<span class="xref">System.Object.GetHashCode()</span>
</div>
<div>
<span class="xref">System.Object.GetType()</span>
</div>
<div>
<span class="xref">System.Object.MemberwiseClone()</span>
</div>
<div>
<span class="xref">System.Object.ReferenceEquals(System.Object, System.Object)</span>
</div>
<div>
<span class="xref">System.Object.ToString()</span>
</div>
</div>
<h6><strong>Namespace</strong>: <a class="xref" href="FreeSql.html">FreeSql</a></h6>
<h6><strong>Assembly</strong>: FreeSql.dll</h6>
<h5 id="FreeSql_FreeSqlBuilder_syntax">Syntax</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public class FreeSqlBuilder</code></pre>
</div>
<h3 id="methods">Methods
</h3>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_Build.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.Build%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L227">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_Build_" data-uid="FreeSql.FreeSqlBuilder.Build*"></a>
<h4 id="FreeSql_FreeSqlBuilder_Build" data-uid="FreeSql.FreeSqlBuilder.Build">Build()</h4>
<div class="markdown level1 summary"></div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public IFreeSql Build()</code></pre>
</div>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">IFreeSql</span></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_Build__1.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.Build%60%601%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L228">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_Build_" data-uid="FreeSql.FreeSqlBuilder.Build*"></a>
<h4 id="FreeSql_FreeSqlBuilder_Build__1" data-uid="FreeSql.FreeSqlBuilder.Build``1">Build&lt;TMark&gt;()</h4>
<div class="markdown level1 summary"></div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public IFreeSql&lt;TMark&gt; Build&lt;TMark&gt;()</code></pre>
</div>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">IFreeSql</span>&lt;TMark&gt;</td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="parametername">TMark</span></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseAdoConnectionPool_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseAdoConnectionPool(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L60">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseAdoConnectionPool_" data-uid="FreeSql.FreeSqlBuilder.UseAdoConnectionPool*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseAdoConnectionPool_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseAdoConnectionPool(System.Boolean)">UseAdoConnectionPool(Boolean)</h4>
<div class="markdown level1 summary"><p>使用原始连接池ado.net、odbc、oledb<p>
默认false<p>
UseConnectionString 默认使用 FreeSql 连接池,有以下特点:<p>
<ul>
<li>状态不可用,断熔机制直到后台检测恢复<p></li>
<li>读写分离,从库不可用,会切换其他可用从库<p></li>
<li>监测连接池使用情况fsql.Ado.Statistics<p>
有部分使用者不喜欢【断熔机制】,可使用此设置</li>
</ul>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseAdoConnectionPool(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseAutoSyncStructure_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseAutoSyncStructure(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L104">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseAutoSyncStructure_" data-uid="FreeSql.FreeSqlBuilder.UseAutoSyncStructure*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseAutoSyncStructure_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseAutoSyncStructure(System.Boolean)">UseAutoSyncStructure(Boolean)</h4>
<div class="markdown level1 summary"><p>【开发环境必备】自动同步实体结构到数据库,程序运行中检查实体表是否存在,然后创建或修改<p>
注意:生产环境中谨慎使用</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseAutoSyncStructure(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td><p>true:运行时检查自动同步结构, false:不同步结构(默认)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseConfigEntityFromDbFirst_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseConfigEntityFromDbFirst(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L116">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseConfigEntityFromDbFirst_" data-uid="FreeSql.FreeSqlBuilder.UseConfigEntityFromDbFirst*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseConfigEntityFromDbFirst_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseConfigEntityFromDbFirst(System.Boolean)">UseConfigEntityFromDbFirst(Boolean)</h4>
<div class="markdown level1 summary"><p>将数据库的主键、自增、索引设置导入,适用 DbFirst 模式,无须在实体类型上设置 [Column(IsPrimary)] 或者 ConfigEntity。此功能目前可用于 mysql/sqlserver/postgresql/oracle。<p>
本功能会影响 IFreeSql 首次访问的速度。<p>
若使用 CodeFirst 创建索引后,又直接在数据库上建了索引,若无本功能下一次 CodeFirst 迁移时数据库上创建的索引将被删除</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseConfigEntityFromDbFirst(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseConnectionFactory_FreeSql_DataType_System_Func_System_Data_Common_DbConnection__System_Type_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseConnectionFactory(FreeSql.DataType%2CSystem.Func%7BSystem.Data.Common.DbConnection%7D%2CSystem.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L89">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseConnectionFactory_" data-uid="FreeSql.FreeSqlBuilder.UseConnectionFactory*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseConnectionFactory_FreeSql_DataType_System_Func_System_Data_Common_DbConnection__System_Type_" data-uid="FreeSql.FreeSqlBuilder.UseConnectionFactory(FreeSql.DataType,System.Func{System.Data.Common.DbConnection},System.Type)">UseConnectionFactory(DataType, Func&lt;DbConnection&gt;, Type)</h4>
<div class="markdown level1 summary"><p>使用自定义数据库连接对象(放弃内置对象连接池技术)</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseConnectionFactory(DataType dataType, Func&lt;DbConnection&gt; connectionFactory, Type providerType = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.DataType.html">DataType</a></td>
<td><span class="parametername">dataType</span></td>
<td><p>数据库类型</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Func</span>&lt;<span class="xref">System.Data.Common.DbConnection</span>&gt;</td>
<td><span class="parametername">connectionFactory</span></td>
<td><p>数据库连接对象创建器</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">providerType</span></td>
<td><p>提供者的类型,一般不需要指定,如果一直提示“缺少 FreeSql 数据库实现包FreeSql.Provider.MySql.dll可前往 nuget 下载”的错误,说明反射获取不到类型,此时该参数可排上用场<p>例如typeof(FreeSql.SqlServer.SqlServerProvider&lt;&gt;)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseConnectionString_FreeSql_DataType_System_String_System_Type_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseConnectionString(FreeSql.DataType%2CSystem.String%2CSystem.Type)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L41">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseConnectionString_" data-uid="FreeSql.FreeSqlBuilder.UseConnectionString*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseConnectionString_FreeSql_DataType_System_String_System_Type_" data-uid="FreeSql.FreeSqlBuilder.UseConnectionString(FreeSql.DataType,System.String,System.Type)">UseConnectionString(DataType, String, Type)</h4>
<div class="markdown level1 summary"><p>使用连接串(推荐)</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseConnectionString(DataType dataType, string connectionString, Type providerType = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.DataType.html">DataType</a></td>
<td><span class="parametername">dataType</span></td>
<td><p>数据库类型</p>
</td>
</tr>
<tr>
<td><span class="xref">System.String</span></td>
<td><span class="parametername">connectionString</span></td>
<td><p>数据库连接串</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Type</span></td>
<td><span class="parametername">providerType</span></td>
<td><p>提供者的类型,一般不需要指定,如果一直提示“缺少 FreeSql 数据库实现包FreeSql.Provider.MySql.dll可前往 nuget 下载”的错误,说明反射获取不到类型,此时该参数可排上用场<p>例如typeof(FreeSql.SqlServer.SqlServerProvider&lt;&gt;)</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseExitAutoDisposePool_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseExitAutoDisposePool(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L221">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseExitAutoDisposePool_" data-uid="FreeSql.FreeSqlBuilder.UseExitAutoDisposePool*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseExitAutoDisposePool_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseExitAutoDisposePool(System.Boolean)">UseExitAutoDisposePool(Boolean)</h4>
<div class="markdown level1 summary"><p>监听 AppDomain.CurrentDomain.ProcessExit/Console.CancelKeyPress 事件自动释放连接池<p>
默认值: true</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseExitAutoDisposePool(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseGenerateCommandParameterWithLambda_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseGenerateCommandParameterWithLambda(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L140">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseGenerateCommandParameterWithLambda_" data-uid="FreeSql.FreeSqlBuilder.UseGenerateCommandParameterWithLambda*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseGenerateCommandParameterWithLambda_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseGenerateCommandParameterWithLambda(System.Boolean)">UseGenerateCommandParameterWithLambda(Boolean)</h4>
<div class="markdown level1 summary"><p>是否生成命令参数化执行,针对 lambda 表达式解析<p>
注意:常量不会参数化,变量才会做参数化<p>
var id = 100;
fsql.Select&lt;T&gt;().Where(a =&gt; a.id == id) 会参数化<p>
fsql.Select&lt;T&gt;().Where(a =&gt; a.id == 100) 不会参数化</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseGenerateCommandParameterWithLambda(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseLazyLoading_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseLazyLoading(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L150">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseLazyLoading_" data-uid="FreeSql.FreeSqlBuilder.UseLazyLoading*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseLazyLoading_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseLazyLoading(System.Boolean)">UseLazyLoading(Boolean)</h4>
<div class="markdown level1 summary"><p>延时加载导航属性对象,导航属性需要声明 virtual</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseLazyLoading(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseMappingPriority_FreeSql_Internal_MappingPriorityType_FreeSql_Internal_MappingPriorityType_FreeSql_Internal_MappingPriorityType_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseMappingPriority(FreeSql.Internal.MappingPriorityType%2CFreeSql.Internal.MappingPriorityType%2CFreeSql.Internal.MappingPriorityType)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L208">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseMappingPriority_" data-uid="FreeSql.FreeSqlBuilder.UseMappingPriority*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseMappingPriority_FreeSql_Internal_MappingPriorityType_FreeSql_Internal_MappingPriorityType_FreeSql_Internal_MappingPriorityType_" data-uid="FreeSql.FreeSqlBuilder.UseMappingPriority(FreeSql.Internal.MappingPriorityType,FreeSql.Internal.MappingPriorityType,FreeSql.Internal.MappingPriorityType)">UseMappingPriority(MappingPriorityType, MappingPriorityType, MappingPriorityType)</h4>
<div class="markdown level1 summary"><p>指定映射优先级<p>
例如表名:实体类名 &lt; Aop &lt; FluentApi &lt; Attribute &lt; AsTable<p>
事件 Aop -------&gt; fsql.Aop.ConfigEntity/fsql.Aop.ConfigEntityProperty<p>
方法 FluentApi -&gt; fsql.CodeFirst.ConfigEntity/fsql.CodeFirst.Entity<p>
特性 Attribute -&gt; [Table(Name = xxx, ...)]<p>
-----------------------------------------------------------------------------<p>
默认规则关于映射优先级Attribute 可以更直观排查问题,即使任何地方使用 FluentApi/Aop 设置 TableName 都不生效。<p>
调整规则UseMappingPriority(Attribute, FluentApi, Aop) <p>
实体类名 &lt; Attribute &lt; FluentApi &lt; Aop &lt; AsTable</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseMappingPriority(MappingPriorityType mappingType1, MappingPriorityType mappingType2, MappingPriorityType mappingType3)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.Internal.MappingPriorityType.html">MappingPriorityType</a></td>
<td><span class="parametername">mappingType1</span></td>
<td></td>
</tr>
<tr>
<td><a class="xref" href="FreeSql.Internal.MappingPriorityType.html">MappingPriorityType</a></td>
<td><span class="parametername">mappingType2</span></td>
<td></td>
</tr>
<tr>
<td><a class="xref" href="FreeSql.Internal.MappingPriorityType.html">MappingPriorityType</a></td>
<td><span class="parametername">mappingType3</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="exceptions">Exceptions</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Condition</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.ArgumentException</span></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseMonitorCommand_System_Action_System_Data_Common_DbCommand__System_Action_System_Data_Common_DbCommand_System_String__.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseMonitorCommand(System.Action%7BSystem.Data.Common.DbCommand%7D%2CSystem.Action%7BSystem.Data.Common.DbCommand%2CSystem.String%7D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L161">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseMonitorCommand_" data-uid="FreeSql.FreeSqlBuilder.UseMonitorCommand*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseMonitorCommand_System_Action_System_Data_Common_DbCommand__System_Action_System_Data_Common_DbCommand_System_String__" data-uid="FreeSql.FreeSqlBuilder.UseMonitorCommand(System.Action{System.Data.Common.DbCommand},System.Action{System.Data.Common.DbCommand,System.String})">UseMonitorCommand(Action&lt;DbCommand&gt;, Action&lt;DbCommand, String&gt;)</h4>
<div class="markdown level1 summary"><p>监视数据库命令对象</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseMonitorCommand(Action&lt;DbCommand&gt; executing, Action&lt;DbCommand, string&gt; executed = null)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Action</span>&lt;<span class="xref">System.Data.Common.DbCommand</span>&gt;</td>
<td><span class="parametername">executing</span></td>
<td><p>执行前</p>
</td>
</tr>
<tr>
<td><span class="xref">System.Action</span>&lt;<span class="xref">System.Data.Common.DbCommand</span>, <span class="xref">System.String</span>&gt;</td>
<td><span class="parametername">executed</span></td>
<td><p>执行后,可监视执行性能</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseNameConvert_FreeSql_Internal_NameConvertType_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseNameConvert(FreeSql.Internal.NameConvertType)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L174">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseNameConvert_" data-uid="FreeSql.FreeSqlBuilder.UseNameConvert*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseNameConvert_FreeSql_Internal_NameConvertType_" data-uid="FreeSql.FreeSqlBuilder.UseNameConvert(FreeSql.Internal.NameConvertType)">UseNameConvert(NameConvertType)</h4>
<div class="markdown level1 summary"><p>实体类名 -&gt; 数据库表名,命名转换(类名、属性名都生效)<p>
优先级小于 [Column(Name = &quot;xxx&quot;)]</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseNameConvert(NameConvertType convertType)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.Internal.NameConvertType.html">NameConvertType</a></td>
<td><span class="parametername">convertType</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseNoneCommandParameter_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseNoneCommandParameter(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L126">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseNoneCommandParameter_" data-uid="FreeSql.FreeSqlBuilder.UseNoneCommandParameter*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseNoneCommandParameter_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseNoneCommandParameter(System.Boolean)">UseNoneCommandParameter(Boolean)</h4>
<div class="markdown level1 summary"><p>不使用命令参数化执行,针对 Insert/Update也可临时使用 IInsert/IUpdate.NoneParameter()</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseNoneCommandParameter(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseQuoteSqlName_System_Boolean_.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseQuoteSqlName(System.Boolean)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L186">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseQuoteSqlName_" data-uid="FreeSql.FreeSqlBuilder.UseQuoteSqlName*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseQuoteSqlName_System_Boolean_" data-uid="FreeSql.FreeSqlBuilder.UseQuoteSqlName(System.Boolean)">UseQuoteSqlName(Boolean)</h4>
<div class="markdown level1 summary"><p>SQL名称是否使用 [] `` &quot;&quot;<p>
true: SELECT .. FROM [table]<p>
false: SELECT .. FROM table</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseQuoteSqlName(bool value)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Boolean</span></td>
<td><span class="parametername">value</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseSlave_System_String___.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseSlave(System.String%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L70">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseSlave_" data-uid="FreeSql.FreeSqlBuilder.UseSlave*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseSlave_System_String___" data-uid="FreeSql.FreeSqlBuilder.UseSlave(System.String[])">UseSlave(String[])</h4>
<div class="markdown level1 summary"><p>使用从数据库,支持多个</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseSlave(params string[] slaveConnectionString)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.String</span>[]</td>
<td><span class="parametername">slaveConnectionString</span></td>
<td><p>从数据库连接串</p>
</td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
<span class="small pull-right mobile-hide">
<span class="divider">|</span>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder_UseSlaveWeight_System_Int32___.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder.UseSlaveWeight(System.Int32%5B%5D)%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A">Improve this Doc</a>
</span>
<span class="small pull-right mobile-hide">
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L76">View Source</a>
</span>
<a id="FreeSql_FreeSqlBuilder_UseSlaveWeight_" data-uid="FreeSql.FreeSqlBuilder.UseSlaveWeight*"></a>
<h4 id="FreeSql_FreeSqlBuilder_UseSlaveWeight_System_Int32___" data-uid="FreeSql.FreeSqlBuilder.UseSlaveWeight(System.Int32[])">UseSlaveWeight(Int32[])</h4>
<div class="markdown level1 summary"></div>
<div class="markdown level1 conceptual"></div>
<h5 class="decalaration">Declaration</h5>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public FreeSqlBuilder UseSlaveWeight(params int[] slaveWeights)</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Name</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><span class="xref">System.Int32</span>[]</td>
<td><span class="parametername">slaveWeights</span></td>
<td></td>
</tr>
</tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-striped table-condensed">
<thead>
<tr>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td><a class="xref" href="FreeSql.FreeSqlBuilder.html">FreeSqlBuilder</a></td>
<td></td>
</tr>
</tbody>
</table>
</article>
</div>
<div class="hidden-sm col-md-2" role="complementary">
<div class="sideaffix">
<div class="contribution">
<ul class="nav">
<li>
<a href="https://github.com/dotnetcore/freesql/new/master/apiSpec/new?filename=FreeSql_FreeSqlBuilder.md&amp;value=---%0Auid%3A%20FreeSql.FreeSqlBuilder%0Asummary%3A%20'*You%20can%20override%20summary%20for%20the%20API%20here%20using%20*MARKDOWN*%20syntax'%0A---%0A%0A*Please%20type%20below%20more%20information%20about%20this%20API%3A*%0A%0A" class="contribution-link">Improve this Doc</a>
</li>
<li>
<a href="https://github.com/dotnetcore/FreeSql/blob/master/FreeSql/FreeSqlBuilder.cs/#L13" class="contribution-link">View Source</a>
</li>
</ul>
</div>
<nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix">
<h5>In This Article</h5>
<div></div>
</nav>
</div>
</div>
</div>
</div>
<footer>
<div class="grad-bottom"></div>
<div class="footer">
<div class="container">
<span class="pull-right">
<a href="#top">Back to top</a>
</span>
<span>Generated by <strong>DocFX</strong></span>
</div>
</div>
</footer>
</div>
<script type="text/javascript" src="../styles/docfx.vendor.js"></script>
<script type="text/javascript" src="../styles/docfx.js"></script>
<script type="text/javascript" src="../styles/main.js"></script>
</body>
</html>