XML文件作为django项目的模型 [英] XML file as model for django project

查看:116
本文介绍了XML文件作为django项目的模型的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个由其他程序管理的XML文件,我正在编写一个Web服务,以便用户能够查询该文件。实质上,我使用的是基于xml的数据库,而不是在Django中使用sql作为模型数据库。



我该怎么做?我发现所有的教程都在后台使用sql数据库。有没有办法使用xml文件作为数据库。

解决方案

有一个包可以做这个可用的 here 。我没有尝试过,但从源头上看,似乎正在做很多你所要求的。


I have a XML file that is managed by other programs, I am writing a web service such that users are able to query this file. In essence i am using a xml based database instead of using sql as the model database in Django.

how do i do this? all the tutorials that i find use a sql database in the backend. is there a way to use the xml file as a database.

解决方案

There's a package to do just this available here. I haven't tried it, but looking through the source, it seems to be doing pretty much what you're asking.

这篇关于XML文件作为django项目的模型的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆