473,399 Members | 4,192 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

sqlite for mac?

Does sqlite come in a mac version?

Thanks.

May 1 '07 #1
14 2942
7stud <bb**********@yahoo.comwrote:
Does sqlite come in a mac version?
Sure, and it's part of the Python 2.5 for the Mac that you can download
from python.org.
Alex
May 1 '07 #2
Does sqlite come in a mac version?
>
The interface (pysqlite) is part of the python 2.5 standard library
but you need to install sqlite itself separately (as far as I
remember) from www.sqlite.org

Daniel
May 1 '07 #3
On May 1, 4:08 am, "Daniel Nogradi" <nogr...@gmail.comwrote:
Does sqlite come in a mac version?

The interface (pysqlite) is part of the python 2.5 standard library
but you need to install sqlite itself separately (as far as I
remember) fromwww.sqlite.org

Daniel
I'm using python 2.4.4 because the download said there were more mac
modules available for 2.4.4. than 2.5, and I can't seem to locate a
place to download sqlite for mac.

May 1 '07 #4
On May 1, 1:12 pm, 7stud <bbxx789_0...@yahoo.comwrote:
I'm using python 2.4.4 because the download said there were more mac
modules available for 2.4.4. than 2.5, and I can't seem to locate a
place to download sqlite for mac.
I it comes on OS X Tiger, and possibly earlier versions as well (it's
used as an index for Mail.app).. You just need to download and
install the pysqlite libraries.

May 1 '07 #5
On May 1, 10:12 am, 7stud <bbxx789_0...@yahoo.comwrote:
On May 1, 4:08 am, "Daniel Nogradi" <nogr...@gmail.comwrote:
Does sqlite come in a mac version?
The interface (pysqlite) is part of the python 2.5 standard library
but you need to install sqlite itself separately (as far as I
remember) fromwww.sqlite.org
Daniel

I'm using python 2.4.4 because the download said there were more mac
modules available for 2.4.4. than 2.5, and I can't seem to locate a
place to download sqlite for mac.

Did you install Xcode on your Mac? If so then you should have access
to a
C compiler allowing you to compile sqlite from source:

http://sqlite.org/download.html

I checked fink (finkproject.org) but that web site shows
no binary distributions for sqlite3:

http://pdb.finkproject.org/pdb/package.php/sqlite3

--
Hope this helps,
Steven
May 1 '07 #6

On May 1, 2007, at 12:39 PM, kirkjobsluder wrote:
On May 1, 1:12 pm, 7stud <bbxx789_0...@yahoo.comwrote:
>I'm using python 2.4.4 because the download said there were more mac
modules available for 2.4.4. than 2.5, and I can't seem to locate a
place to download sqlite for mac.

I it comes on OS X Tiger, and possibly earlier versions as well (it's
used as an index for Mail.app).. You just need to download and
install the pysqlite libraries.
The system sqlite btw (which reports itself as version 3.1.3), is not
the same as what is included in Python 2.5. Will somebody please
say what version of sqlite is supported by Python 2.5?
May 1 '07 #7
I'm using python 2.4.4 because the download said there were more mac
modules available for 2.4.4. than 2.5, and I can't seem to locate a
place to download sqlite for mac.
I it comes on OS X Tiger, and possibly earlier versions as well (it's
used as an index for Mail.app).. You just need to download and
install the pysqlite libraries.

The system sqlite btw (which reports itself as version 3.1.3), is not
the same as what is included in Python 2.5. Will somebody please
say what version of sqlite is supported by Python 2.5
I'm using sqlite 3.3.11 with python 2.5 (on linux) but I guess some
earlier versions will also work.

Daniel
May 1 '07 #8
Does sqlite come in a mac version?

The interface (pysqlite) is part of the python 2.5 standard library
but you need to install sqlite itself separately (as far as I
remember) fromwww.sqlite.org

Daniel

I'm using python 2.4.4 because the download said there were more mac
modules available for 2.4.4. than 2.5, and I can't seem to locate a
place to download sqlite for mac.
If you use python 2.4.4 you can install the pysqlite module from
http://www.initd.org/tracker/pysqlite/wiki/pysqlite (this is the
interface that is included in python 2.5, you need to install sqlite
itself, probably from source, with any python version).

Daniel
May 1 '07 #9
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 2007-05-01, Daniel Nogradi <no*****@gmail.comwrote:
>Does sqlite come in a mac version?

The interface (pysqlite) is part of the python 2.5 standard library
but you need to install sqlite itself separately (as far as I
remember) from www.sqlite.org
http://developer.apple.com/documenta...ection_20.html

- --
Ben Secrest <bl******@gmail.com>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (NetBSD)

iD8DBQFGNy4DeLi5NDZQ3o0RAtVOAJ9AglHEPH/9HUKIsLLWIkaNwoZC8QCaAy7T
MC8VhXY2MyOyp2DaJAPOb0I=
=UGAL
-----END PGP SIGNATURE-----

May 1 '07 #10
On May 1, 6:09 am, Ben Secrest <blsec...@gmail.comwrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 2007-05-01, Daniel Nogradi <nogr...@gmail.comwrote:
Does sqlite come in a mac version?
The interface (pysqlite) is part of the python 2.5 standard library
but you need to install sqlite itself separately (as far as I
remember) fromwww.sqlite.org

http://developer.apple.com/documenta...ual/OSX_Techno...

- --
Ben Secrest <blsec...@gmail.com>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (NetBSD)

iD8DBQFGNy4DeLi5NDZQ3o0RAtVOAJ9AglHEPH/9HUKIsLLWIkaNwoZC8QCaAy7T
MC8VhXY2MyOyp2DaJAPOb0I=
=UGAL
-----END PGP SIGNATURE-----
I downloaded pysqlite, ran the setup script, and tested the
installation and everything worked fine. However, if I try to import
either sqlite, sqlite2, or sqlite3 into a python program, I get an
error saying there's no such module.

I assume that means pysqlite cannot see the installation of SQlite
that came preinstalled on my mac. My python book says to download the
SQlite source where automatic code generation has already been
performed. I did that. Then my book says says to follow the
instructions in the README file. However, the download only has two
files: sqlite3.c and sqlite3.h. As a result, I don't know what to
do.

Any advice?

May 3 '07 #11
Did you install Xcode on your Mac?

Yes, Xcode 2.4.

May 3 '07 #12
>Does sqlite come in a mac version?
The interface (pysqlite) is part of the python 2.5 standard library
but you need to install sqlite itself separately (as far as I
remember) fromwww.sqlite.org
http://developer.apple.com/documenta...ual/OSX_Techno...

I downloaded pysqlite, ran the setup script, and tested the
installation and everything worked fine. However, if I try to import
either sqlite, sqlite2, or sqlite3 into a python program, I get an
error saying there's no such module.

I assume that means pysqlite cannot see the installation of SQlite
that came preinstalled on my mac. My python book says to download the
SQlite source where automatic code generation has already been
performed. I did that. Then my book says says to follow the
instructions in the README file. However, the download only has two
files: sqlite3.c and sqlite3.h. As a result, I don't know what to
do.
If all tests ran fine then pysqlite can see your sqlite installation.
How are you importing sqlite? It's usually something like "from
pysqlite2 import dbapi2 as sqlite" not simply "import sqlite". If you
go to the test directory where everything works you can see how those
modules import it and that should definitely work for you as well.

HTH,
Daniel
May 3 '07 #13
Per the pysqlite installation instructions, this is the test I ran to
confirm that pysqlite installed correctly
>from pysqlite2 import test
test.test()
and I got output similar to what the docs say should happen:
>ran 101 tests in 0.182s
My python book, "Beginning Python: From Novice to Professional"(2005),
after giving some brief installation instructions for SQLite and
pysqlite, says:

"Once you have pysqlite installed, you can import it as a module,
under the name sqlite."

and then the author provides this example:
>>>import sqlite
conn = sqlite.connect('somedatabase.db')
>>>curs = conn.cursor()
This cursor can then be used to make SQL queries...
>>>conn.commit()
conn.close()
So that is what I tried. Then I changed "sqlite" to "sqlite2" and
"sqlite3" as well.

May 3 '07 #14
On May 3, 8:37 am, "Daniel Nogradi" <nogr...@gmail.comwrote:
>
If all tests ran fine then pysqlite can see your sqlite installation.
How are you importing sqlite? It's usually something like "from
pysqlite2 import dbapi2 as sqlite" not simply "import sqlite".
I just checked the errata for the book, and it says to use the import
statement you suggested:
from pysqlite2 import dbapi2 as sqlite
May 3 '07 #15

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: David Fowler | last post by:
I'm new to getting in touch with other PHP users/PHP team, so please excuse me if this post is at all inappropriate or in the wrong place. In the current release of PHP (5.1.4) and in the CVS for...
12
by: John Salerno | last post by:
I've been looking around and reading, and I have a few more questions about SQLite in particular, as it relates to Python. 1. What is the current module to use for sqlite? sqlite3? or is that not...
4
by: Jim Carlock | last post by:
I added the following lines to PHP.INI. extension=php_pdo.dll extension=php_pdo_sqlite.dll extension=php_sqlite.dll specifically in that order. I noticed the extensions getting loaded are...
10
by: Luigi | last post by:
Hello all! I'm a newbie in PHP. I have written a short script that tries to update a SQLite database with the user data. It is pretty simple, something like this: <?php $sqlite =...
9
by: Gilles Ganault | last post by:
Hello I was looking for a lighter web server than Apache, and installed Lighttpd on CentOS through yum. It works fine, but I now need to use SQLite from a PHP script. I seem to understand that...
8
by: Gilles Ganault | last post by:
Hello I need to compile PHP5 with SQLite statically and without PDO. I don't need DB-independence, so it's fine using sqlite_*() functions instead of PDO. 1. I've downloaded, compiled, and...
3
by: Daniel Fetchinson | last post by:
Does Python 2.5.2's embedded SQLite support full text searching? Sqlite itself is not distributed with python. Only a python db api compliant wrapper is part of the python stdlib and as such it...
0
by: Joe Goldthwaite | last post by:
Thanks Guilherme. That helped. I guess I was thinking that pysqlite would automatically come with some version of sqlite. The fact that it doesn't is what was causing me to get the strange...
20
by: timotoole | last post by:
Hi all, On a (sun) webserver that I use, there is python 2.5.1 installed. I'd like to use sqlite3 with this, however sqlite3 is not installed on the webserver. If I were able to compile sqlite...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.