Sphinxsearch + SQL Server =未知类型'mssql';跳绳

时间:2017-12-15 16:53:58

标签: sql-server sphinx

我正在尝试从SQL Server索引一些数据并且没有运气:

Ubuntu 16.04

public static void waitForAjaxToFinish() {

    WebDriverWait wait = new WebDriverWait(driver, 5000);
    wait.until(new ExpectedCondition<Boolean>() {

        public Boolean apply(WebDriver wdriver) {
            return ((JavascriptExecutor) driver).executeScript("return jQuery.active == 0").equals(true);
        }

    });
}

/etc/sphinxsearch/sphinx.conf

apt-get install sphinxsudo add-apt-repository ppa:builds/sphinxsearch-rel22
apt-get update
apt-get install sphinxsearch

索引器 - 所有

source src1
{
        # data source type. mandatory, no default value
        # known types are mysql, pgsql, mssql, xmlpipe, xmlpipe2, odbc
        type = mssql

        #####################################################################
        ## SQL settings (for 'mysql' and 'pgsql' types)
        #####################################################################

        # some straightforward parameters for SQL source types
        sql_host = 192.168.*.*
        sql_user = ****
        sql_pass = ****
        sql_db   = DatabaseName
        sql_port = 1433  # optional, default is 3306
        ...
}

毕竟我已尝试从源代码编译sphinx,但配置文件中没有Sphinx 2.2.9-id64-release (rel22-r5006) Copyright (c) 2001-2015, Andrew Aksyonoff Copyright (c) 2008-2015, Sphinx Technologies Inc (http://sphinxsearch.com) using config file '/etc/sphinxsearch/sphinx.conf'... indexing index 'test1'... ERROR: source 'src1': unknown type 'mssql'; skipping. ERROR: index 'test1': failed to configure some of the sources, will not index. 选项:

with-mssql

有没有机会让sphinxsearch能够从SQL Server索引数据?感谢您的关注和解答!祝你有愉快的一天!

1 个答案:

答案 0 :(得分:1)

我认为MSSQL驱动程序仅适用于Windows版本。从历史上看,MSSQL不适用于linux,所以驱动程序从未在linux上实现过。

也许可以使用ODBC驱动程序(我认为是http://www.unixodbc.org/

发现了这个:http://www.unixodbc.org/doc/FreeTDS.html