使用Web-Harvester的MSSQL-Server需要做什么?

时间:2013-12-19 18:48:37

标签: java sql-server jdbc

主题几乎说了一切。我已经下载了Microsoft SQL-Server JDBC驱动程序。但是我如何将它们与网络收割机一起使用? https://sourceforge.net/p/web-harvest/

我有:

<database connection="jdbc:sqlserver://192.168.1.115;databaseName=IMDB;user=sa;password=xxxxxxxxxxxxx ;" jdbcclass="com.microsoft.sqlserver.jdbc.SQLServerDriver">
<template>
INSERT INTO First (imdbid, titel, [plot-kurz], laufzeit)
values (${myId}, '${myUrl}', '${myText}', '${mySource}')
</template>
</database>

但是我得到了这些话:

  

org.webharvest.exception.DatabaseException:
  com.microsoft.sqlserver.jdbc.SQLServerException:der中的Falsche语法   Nähevon','。在
  org.webharvest.runtime.processors.plugins.DatabasePlugin.executePlugin(DatabasePlugin.java:132)   在   org.webharvest.runtime.processors.WebHarvestPlugin.execute(WebHarvestPlugin.java:125)   在   org.webharvest.runtime.processors.BaseProcessor.run(BaseProcessor.java:115)   在   org.webharvest.runtime.processors.BodyProcessor.execute(BodyProcessor.java:25)   在   org.webharvest.runtime.processors.BaseProcessor.run(BaseProcessor.java:115)   在   org.webharvest.runtime.processors.CaseProcessor.execute(CaseProcessor.java:68)   在   org.webharvest.runtime.processors.BaseProcessor.run(BaseProcessor.java:115)   在   org.webharvest.runtime.processors.BodyProcessor.execute(BodyProcessor.java:25)   在   org.webharvest.runtime.processors.EmptyProcessor.execute(EmptyProcessor.java:58)   在   org.webharvest.runtime.processors.BaseProcessor.run(BaseProcessor.java:115)   在   org.webharvest.runtime.processors.BodyProcessor.execute(BodyProcessor.java:25)   在   org.webharvest.runtime.processors.BaseProcessor.run(BaseProcessor.java:115)   在   org.webharvest.runtime.processors.LoopProcessor.execute(LoopProcessor.java:116)   在   org.webharvest.runtime.processors.BaseProcessor.run(BaseProcessor.java:115)   在   org.webharvest.runtime.processors.BodyProcessor.execute(BodyProcessor.java:25)   在   org.webharvest.runtime.processors.WhileProcessor.execute(WhileProcessor.java:94)   在   org.webharvest.runtime.processors.BaseProcessor.run(BaseProcessor.java:115)   在org.webharvest.runtime.Scraper.execute(Scraper.java:166)at   org.webharvest.runtime.Scraper.execute(Scraper.java:179)at   org.webharvest.gui.ScraperExecutionThread.run(ScraperExecutionThread.java:56)   引起:com.microsoft.sqlserver.jdbc.SQLServerException:Falsche   derNähevon','中的语法。在   com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:216)   在   com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(SQLServerStatement.java:1515)   在   com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(SQLServerPreparedStatement.java:404)   在   com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement $ PrepStmtExecCmd.doExecute(SQLServerPreparedStatement.java:350)   在com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:5696)   在   com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1715)   在   com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:180)   在   com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:155)   在
  com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.execute(SQLServerPreparedStatement.java:332)   在
  org.webharvest.runtime.processors.plugins.DatabasePlugin.executePlugin(DatabasePlugin.java:84)       ......还有19个

1 个答案:

答案 0 :(得分:0)

您的连接似乎正在运行 - 该错误是SQL Server告诉您它的查询错误。例如:如果$ {myID}正在评估为空字符串。