<div dir="ltr">Hi,<div><br></div><div>I've seen that there is support for BCP bulk load support since gdal 2.1.0, but from other posts in this list and all mentions in the docs, it looks as if this support is only available for Windows, not unix (I hope I am wrong and my problem comes from somewhere else), e.g.:</div><div><p class="MsoNormal" style="margin:0cm 0cm 0.0001pt;font-size:11pt;font-family:Calibri,sans-serif"></p><ul><li><a href="https://lists.osgeo.org/pipermail/gdal-dev/2018-May/048520.html" style="color:rgb(5,99,193)">https://lists.osgeo.org/pipermail/gdal-dev/2018-May/048520.html</a></li><li><a href="http://osgeo-org.1560.x6.nabble.com/gdal-dev-connect-mssql-from-linux-td5363547.html">http://osgeo-org.1560.x6.nabble.com/gdal-dev-connect-mssql-from-linux-td5363547.html</a></li></ul><p></p></div><div><br></div><div><br></div><div>And here: <a href="https://gdal.org/drivers/vector/mssqlspatial.html#configuration-options">https://gdal.org/drivers/vector/mssqlspatial.html#configuration-options</a></div><div><br></div><div>"<font size="1"><strong style="box-sizing:border-box;color:rgb(64,64,64);font-family:Lato,proxima-nova,"Helvetica Neue",Arial,sans-serif;background-color:rgb(252,252,252)">MSSQLSPATIAL_USE_BCP</strong><span style="color:rgb(64,64,64);font-family:Lato,proxima-nova,"Helvetica Neue",Arial,sans-serif;background-color:rgb(252,252,252)">: (From GDAL 2.1.0) Enable bulk insert when adding features. This option requires to to compile GDAL against a bulk copy enabled ODBC driver like SQL Server Native Client 11.0. To specify a BCP supported driver in the connection string, use the driver parameter, like DRIVER={SQL Server Native Client 11.0}. If GDAL is compiled against SQL Server Native Client 10.0 or 11.0 the driver is selected automatically not requiring to specify that in the connection string. If GDAL is compiled against SQL Server Native Client 10.0 or 11.0 the default setting of this parameter is TRUE, otherwise the parameter is ignored by the driver."</span></font></div><div><br></div><div>It all references SQL Server Native Client and even in the code I've seen "sqlncli", whereas the driver in Linux for SQL Server is called "ODBC Driver XX for SQL Server", e.g.:</div><div><br></div><div>[ODBC Driver 17 for SQL Server]<br>Description=Microsoft ODBC Driver 17 for SQL Server<br>Driver=/opt/microsoft/msodbcsql17/lib64/libmsodbcsql-17.5.so.2.1<br></div><div><br></div><div>(Also, what does "compile GDAL against a bulk copy enabled ODBC driver like" mean? I have built GDAL from source, configuring it with the flag --enable-driver-mssqlspatial)</div><div><br></div><div>So I am wondering how does gdal checks if there is BCP Support? Like these lines that i.e. #ifdef MSSQL_BCP_SUPPORTED? Is it a "Windows"-check feature?</div><div><br></div><div>I am asking because we have gdal and SQL Server on a CentOS machine and we certainly have BCP, SQLCMD and other SQL Server tools available, but when using ogr2ogr to load source files into a SQL Server instance it does not use BCP. It instead loads one-by-one and this causes the process to be really slow.</div><div><br></div><div>SQL Server version: 2017</div><div>GDAL version: 3.0.4</div><div><br></div><div>Any help/tips will be very appreciated.</div><div><br></div><div>Thanks</div><div><br></div><div>Hector Muro </div></div>