Fwd: Database applications in OS X
Fwd: Database applications in OS X
- Subject: Fwd: Database applications in OS X
- From: Andy Satori <email@hidden>
- Date: Mon, 24 Nov 2003 15:41:26 -0500
Man, I wish Mail.app didn't loose the account when you Move it to a
Folder by rule....
Begin forwarded message:
From: Andy Satori <email@hidden>
Date: November 24, 2003 3:15:23 PM EST
To: George Bridgeman <email@hidden>
Cc: email@hidden
Subject: Re: Database applications in OS X
I've been down this path from several different angles, so let me
start with that.
As I currently see it, you have 4 options:
(1) Use JDBC and the Java bridge to wire your Cocoa applications to the
available JDBC drivers (Oracle, PostgresSQL, Sybase, and SQL Server
all have working drivers)
(2) Use ODBC and either use commercial third party drivers, or attempt
to use the open source solutions. OS X does ship with a usable
ODBC
subsystem, and the C headers are code compatible with the Windows
implementations.
(3) Write your own DB Library interface to each native interface you
wish to support via loadable Bundles. This would give you the most
performance and flexibility, but also costs the most in development
funds.
(4) Select a single DB engine and use it exclusively. There are a few
vendors that offer excellent OS X support with nice native
libraries
for data access. OpenBase being the one that Apple apparently
likes
as that is the one they ship with WebObjects.
Of these options, I found 1 to be the easiest, but the slowest (by a
large margin). I found 2 to be the most painful, but the most
attractive from a code portability standpoint. I ended up doing 3 for
Postgres for my specific needs, though I seriously considered SQL
Server and using the TDS libraries. I seriously evaluated 4, and even
prototyped my project using this method. If it hadn't been for the
costs involved in deployment, I probably would have elected to go this
way. But being as the project was a very low budget project, and I
had existing Postgres and SQL Server infrastructure, this was
ultimately ruled out by price alone.
All of this brings me to the next issue. At present, writing a
Database oriented application is not much fun in Cocoa. Largely
because you have to implement an enormous amount of the Document
Application code yourself to obtain the Document Application feature,
as you cannot effectively override the OpenFile process with an
alternate process to load your data from the database.
This is, in my opinion, one of the biggest remaining hurdles for OS X
to overcome to being a serious player in the enterprise marketplace.
In the enterprise world, everything is in a database of some variety.
Easily getting to that data is critical. ODBC, ADO, and OLEDB
accomplish these tasks with incredible ease. Simply establishing an
easy to use ODBC interface would probably be a start, getting some
decent ODBC drivers running on OS X would be a great second step.
The FreeTDS project has an OpenSource ODBC driver, the should work
(but doesn't), that would get SQL Server and Sybase. Postgres also
has one that apparently works, though I've had no luck, and it seems
to be geared towards php, so there is no decent documentation on
getting it set up. The commericial products are out there, but they
are costly for a per seat license. In many cases, the drivers
themselves frequently cost more than the applications that seek to
make use of them.
Andy Satori - Druware Software Designs - email@hidden
On Nov 24, 2003, at 12:03 PM, George Bridgeman wrote:
Hi people,
I'm currently investigating how to write database applications on Mac
OS X, but having great difficulty in finding any information. I'll
explain what I'm trying to do and if anyone can help me, that'd be
grand:
1. Connect to any type of database (MySQL, Oracle, etc) from within a
Cocoa application written in Objective-C
2. Use Rendezvous from within the application
3. Use little (if any) Java
My questions are thus:
1. Driver availability is sketchy - Oracle has JDBC drivers for OS X
but no Oracle Client install that I can find. Would using the JDBC
drivers for Oracle require an Oracle installation on the same
machine?
2. Is it possible to use Java and Objective-C within the same Cocoa
project (Java for the database interaction, Objective-C for
Rendezvous and everything else, and then call the Java code from the
Objective-C code)
3. Why is Java frowned upon when it comes to writing Cocoa
applications (slightly off-topic, but I was wondering why this is
so)?
4. Is it possible to write Objective-C code to connect to a database?
Which framework(s) would I need to use? Are they open source? Does
Apple have any frameworks to do this? If not, why not?
Sorry this is kind of a long question, but any help would be greatly
appreciated.
Thanks in advance,
George.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.