Re: Newbie: how to build data base
Re: Newbie: how to build data base
- Subject: Re: Newbie: how to build data base
- From: Brian Hill <email@hidden>
- Date: Wed, 6 Jun 2001 20:37:54 -0500
I'am used to 4th Dimention)'s developpement.
I'd like now to make a personnal data base using Obj. C - Cocoa, but i
got in troubles on how to manage the NSTableDataSource, and more on how
i should write the tables to persistant storage with their indexes and
'links'.
I have no Idea about how to build indexes for Table's fields and how to
link 2 Tables with a field from a '1 to n relation'.
I'd like to know what is a HashTable, how to build and use one, etc
does someone know were i could learn about this ?
Is there something to help me in the Cocoa Framework ?
On Wednesday, June 6, 2001, at 07:19 PM, Scott Anguish wrote:
It sounds like you're trying to write a front end to a database, such
as
mysql which you mentioned. I wouldn't actually recommend MySQL
personally -
if you're looking for something you can use for free while you're
developing (or even for some production work), check out FrontBase
(http://www.frontbase.com).
The saddest thing is that with Cocoa/EOF you were able to write a
basic database application without ANY code.
Populating the table, editing, master detail.
Worked with anything that there were EOAdaptors for. (so, FB,
OpenBase, mSQL, postgress, etc..)
Before I go ranting off on how bad it is that the EOPalette.palette in
WO 4.5.1 is broken (and I'd like to...), first I'd ask yourself what you
need to build the database for. Is it a learning exercise for yourself,
or something you need to do for a workplace? I ask, because I used to
code quite a lot of 4th Dimension stuff myself, and it was typically a
business tool, not a hobby tool.
If it's something you need to do for your workplace, and you are used to
writing 4th Dimension code, you might just want to wait until 4th
Dimension is carbonized (which is supposed to be soon...).
There's lots of reasons I personally don't want to do anything in 4th
Dimension/ACI anymore, but if it works for you, why not take the path of
least resistance.
Another option I found interesting is OpenBase.com's RADStudio. If it's
work for a business, and they have some bucks, you should give it a
look. I'm not sure how far you can push it, but the database is great,
and also has liberal developer licensing. OpenBase also has a nice set
of Cocoa classes as well.
That being said, it USED to be (up to and including OS X Server 1.2...)
that an easy way to write a database desktop client app was using
Cocoa/EOF. It was one of the reasons I put OSX on so many desktops at
our business.
Unfortunately, while you can still buy it at the Apple Store, it doesn't
work anymore.
Otherwise, as a hobby pursuit, I'd get either OpenBase or FrontBase and
use their API's instead of writing your own database engine. The only
person I've ever heard of who thought writing database engines was 'fun'
was Tim Wood from the OmniGroup. Using a Cocoa wrapper for a database
lets you concentrate on the fun part of writing the app.
Brian
ps. if you absolutely must write your own database engine for fun, I've
been playing with putting some Core Foundation and Cocoa wrappers around
the database functions in db.h. The db.h engine can a fair amount of
data, but you have to create your own management system for the
'tables'. It's great for a small app, like a newsreader, but not great
for payroll system.
email@hidden
http://personalpages.tds.net/~brian_hill
"Why? I came into this game for adventure - go anywhere, travel
light, get in, get out, wherever there's trouble, a man alone.
Now they've got the whole country sectioned off and you can't
move without a form. I'm the last of a breed."
-- Archibald "Harry" Tuttle, Rogue HVAC Repairman