[ANN] ODBCKit Framework
[ANN] ODBCKit Framework
- Subject: [ANN] ODBCKit Framework
- From: Andrew Satori <email@hidden>
- Date: Fri, 8 Sep 2006 18:04:21 -0400
So I've grumbled often enough about the lack of good Database Access
on the Mac platform and the halfway supported ODBC. I guess I should
be the one to do some thing about it. So I did,
First, the Kit,
ODBCKit is now available as a binary install, the Framework goes into
the usual location (/Library/Frameworks/ or ~/Library/Frameworks/)
and provides a set of Cocoa classes to access ODBC datasources. I
have tested this primarily against the Actual Technologies drivers,
though the PostgreSQL pgODBC driver from gborg.postgresql.org is
known to work as well.
I consider this a 0.1 revision, and have tagged it as such, but it
does work for the basics. What it doesn't do is threaded or asynch
queries (version 0.3) or BLOB's (0.2). Other than that, I'm not to
the stage where I need people to use it and let me know what they
need and what doesn't work for them.
The kit itself contains to key classes: ODBCConnection for the
connecting and running queries. A single Connection object support
multiple queries, and you can -exec a command and return no resultset
set, or you can -open a query and use the results in the form of an
ODBCRecordset. For those of you that have used ADODB on Windows, or
JDBC in Java, this should feel quite familiar. There is one little
bonus, if you don't want to write your own login screen, you don't
have to, the kit also includes an ODBCLogin which can be used to
create the ODBCConnection using the following code:
- (IBAction)onLogin:(id)sender
{
ODBCLogin *login = [[ODBCLogin alloc] init];
[login beginModalLoginForWindow:window];
}
and handling the results by adding a method to the delegate of the
NSWindow (window in the above example):
- (void)loginCompleted:(ODBCConnection *)connection
{
conn = [connection retain];
if (![conn isConnected]) {
[NSApp terminate:self];
NSLog(@"Unable to establish connection to the datasource.");
return;
}
// get the table list,
[tableList removeAllItems];
ODBCRecordset *rs = [conn tables];
while (![rs isEOF])
{
[tableList addItemWithTitle:[[rs fieldByName:@"table_name"]
asString]];
[rs moveNext];
}
[rs close];
[rs release];
}
Second, I decided to try something new regarding this project. In
the past software has either been shareware, commercial or open
source. This project, I'm releasing as free software in that it is
free to use in binary form. I am then offering the Source code to
the community once a certain level of donation's have been made. The
number to reach is $7500 US. When that number is reached I'll publish
all of the code to that point and commit to keeping the code public
and current from then on. I will do so under a BSD license, making it
really free. I'm placing no time limit on getting there either.
So without further ado, the ODBCKit is available from http://
www.druware.com/products/odbckit.html
Thanks, and hope this helps others, I'm already using it heavily for
my internal projects, and I've got a couple of users that have been
using it all day every day for about 2 weeks.
Andy Satori
Owner/Operator/Janitor
Druware Software Designs
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden