[英]How to sync a database field's content with a text file's content?
Here's the situation: we're building our own CMS, and what the boss wants is using a system like Dropbox (local), in order to synchronize the content of CMS documents with the developer's local text files (Something like using SVN, but instead of using File system to store the content of the CMS document's source code, use the DB). 情况是这样的:我们正在构建自己的CMS,而老板希望使用的是Dropbox(本地)之类的系统,以便将CMS文档的内容与开发人员的本地文本文件同步(类似于使用SVN,但相反使用文件系统存储CMS文档源代码的内容,请使用DB)。 We're using MS SQL Server 2005 to store the content, and that's where the tricky part is: how to edit a text file, save it and it appears in the required database field.
我们使用MS SQL Server 2005来存储内容,这是棘手的部分:如何编辑文本文件,保存文本,该文本文件将显示在所需的数据库字段中。
The following T-SQL technique could be the solution: The TSQL of Text Files 以下T-SQL技术可能是解决方案: 文本文件的TSQL
But the boss said 'avoid using this, and any other text-file-to-db, db-to-text-file technique'. 但老板说“避免使用此方法,以及其他任何将文本文件转换为db或db-to-text-file的技术”。 So he wants something already done, simply to skip the logging in the CMS and editing the CMS document, instead edit a local file, save it and .. done.
因此,他希望已经完成的工作,只是跳过CMS中的日志记录并编辑CMS文档,而是编辑本地文件,保存并完成。
It sounds impossible to me (if we don't use the T-SQL technique), I did a 2 week research before writing this, but it's worth a shot, you're the bests here. 这对我来说听起来是不可能的(如果我们不使用T-SQL技术),在编写此书之前我做了2周的研究,但值得一试,您是这里的佼佼者。
Write a client application to get the text file process it and synchronize it with database. 编写一个客户端应用程序以获取文本文件以对其进行处理并将其与数据库同步。 like an intermediate program.
像一个中间程序。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.