平面文件,Python可访问数据库? [英] Flat file, Python accessible database?

查看:83
本文介绍了平面文件,Python可访问数据库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在谷歌搜索_small_,平面文件(没有服务器进程),

类似SQL的数据库,可以从Python轻松访问。速度和

性能没有问题,最重要的是所有数据都包含在单个文件中的
,并且没有服务器二进制文件必须运行才能使用

dbase。哦,我在Cygwin下使用Python。


当然,最受欢迎的是易用性和简单性:)。我现在正在玩SQLite + PySQLite和BerkeleyDB,但这两个似乎是一个

矫枉过正:(。


提前致谢...


-

_______ Karlo Lozovina - Mosor

| | | .---- -.-----。web: http://www.mosor.net | | ICQ#:10667163

| || _ | _ | Parce mihi domine quia Dalmata sum。

| __ | _ | __ || _____ | _____ |

I''ve been Googling around for _small_, flat file (no server processes),
SQL-like database which can be easily access from Python. Speed and
perforamnce are of no issue, most important is that all data is contained
within single file and no server binary has to run in order to use the
dbase. Oh, and I''m using Python under Cygwin.

Ofcourse, ease of use and simplicity is most welcomed :). I''m currently
playing around SQLite+PySQLite and BerkeleyDB, but those two seem like an
overkill :(.

Thanks in advance...

--
_______ Karlo Lozovina - Mosor
| | |.-----.-----. web: http://www.mosor.net || ICQ#: 10667163
| || _ | _ | Parce mihi domine quia Dalmata sum.
|__|_|__||_____|_____|

推荐答案

Karlo Lozovina< _karlo _ @ _ mosor.net_>写道:
Karlo Lozovina <_karlo_@_mosor.net_> writes:
我一直在谷歌搜索_small_,平面文件(没有服务器进程),类似SQL的数据库,可以从Python轻松访问。
I''ve been Googling around for _small_, flat file (no server
processes), SQL-like database which can be easily access from Python.




如果你需要它是SQL-比如,SQLite似乎是正确的。


我不清楚你的意思是扁平fil在这里,但如果你的意思是

它应该是人类可读的,也许csv模块就是那个。

http://docs.python.org/lib/module-csv.html


-

Bj ?? rn Lindstr ?? m< bk ** @ stp.lingfil.uu.se>

计算语言学学生,乌普萨拉瑞典大学



If you need it to be SQL-like, SQLite seems to be the right thing.

It''s not clear to me what you mean by "flat" file here, but if you mean
it should be human readable, maybe the csv module is the thing.

http://docs.python.org/lib/module-csv.html

--
Bj??rn Lindstr??m <bk**@stp.lingfil.uu.se>
Student of computational linguistics, Uppsala University, Sweden


Karlo Lozovina写道:
Karlo Lozovina wrote:
我一直在谷歌搜索_small_,平面文件(没有服务器进程), dbase。哦,我在Cygwin下使用Python。
I''ve been Googling around for _small_, flat file (no server processes),
SQL-like database which can be easily access from Python. Speed and
perforamnce are of no issue, most important is that all data is contained
within single file and no server binary has to run in order to use the
dbase. Oh, and I''m using Python under Cygwin.




取决于你的意思类似SQL您可能会喜欢KirbyBase
http://www.netpromi.com/kirbybase。 html


Kent



Depending on what you mean by "SQL-like" you might like KirbyBase
http://www.netpromi.com/kirbybase.html

Kent


11月01日,Karlo Lozovina写道:
On Nov 01, Karlo Lozovina wrote:
I一直在谷歌搜索_small_,平面文件(没有服务器进程),类似SQL的数据库,可以从Python轻松访问。速度和性能没有问题,最重要的是所有数据都包含在单个文件中,并且没有服务器二进制文件必须运行才能使用dbase。哦,我在Cygwin下使用Python。

当然,最受欢迎的是易用性和简单性:)。我现在正在玩SQLite + PySQLite和BerkeleyDB,但那两个看起来像是一种矫枉过正:(。
I''ve been Googling around for _small_, flat file (no server
processes), SQL-like database which can be easily access from
Python. Speed and perforamnce are of no issue, most important is
that all data is contained within single file and no server binary
has to run in order to use the dbase. Oh, and I''m using Python under
Cygwin.

Ofcourse, ease of use and simplicity is most welcomed :). I''m
currently playing around SQLite+PySQLite and BerkeleyDB, but those
two seem like an overkill :(.




不确定类似于SQL,但conf / ini文件类型可以是

被认为是一种合理的数据库格式,以满足简单需求,并且很容易解析/写入。
。这里记录了ConfigParser:

http://www.python.org/doc/current/li...figParser.html


Fredrik Lundh的示例用法如下:<

http://effbot.org/librarybook/configparser.htm


此处描述了初始化文件格式:

http://en.wikipedia.org/wiki/INI_file

-

_ _ ___

| V | icah | - lliott http:// micah。 elliott.name md*@micah.elliott.name

" " """



Not sure about "SQL-like", but the conf/ini file type could be
considered a reasonable database format for simple needs, and is
easy to parse/write. The ConfigParser is documented here:

http://www.python.org/doc/current/li...figParser.html

And Fredrik Lundh''s examples usage is here:

http://effbot.org/librarybook/configparser.htm

And the Initialization File format is described here:

http://en.wikipedia.org/wiki/INI_file

--
_ _ ___
|V|icah |- lliott http://micah.elliott.name md*@micah.elliott.name
" " """


这篇关于平面文件,Python可访问数据库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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