简体   繁体   English

如何将数据库字段的内容与文本文件的内容同步?

[英]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.

相关问题 将文本字段内容发布到Firebase数据库 - Posting text field content to Firebase Database 如何将联系表单的内容保存到wordpress数据库并在仪表板中访问? - How to save contact form's content to wordpress database and access in dashboard? 如何在另一个字段的任何行中查找具有一个字段内容的MySQL记录 - How to find MySQL records having one field's content within any row of another field 比较单选按钮的文本和数据库字段 - Comparing radio button's text and a database field 如何读取文件并将其内容添加到数据库? - How to read a file and add its content to database? 在数据库中存储格式化内容的标准方法是什么? - What's the standard way to store formatted content in the database? Google App Engine:在用户帐户上保留数据库内容 - Google App Engine: Persist database content on a user's account 在> = Rails 3.2.0中创建“测试”数据库内容的最佳方法是什么? - What's the best method for creating “test” database content in >= Rails 3.2.0? 在具有大量内容的数据库中存储文件 - Storing a file in database with huge content 存储网站内容:数据库还是文件? - Storing website content: database or file?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM