log in | register | forums
Show:
Go:
Forums
Username:

Password:

User accounts
Register new account
Forgot password
Forum stats
List of members
Search the forums

Advanced search
Recent discussions
- R-Comp releases Genealogy v2 (News:)
- Will we see 5.30 released at Wakefield show? (News:1)
- Sine Nomine updates RiscOSM and Impact (News:)
- Netfetch version 5.55 released (News:)
- Prizes for Wakefield Show announced (News:)
- Heretic update from R-Comp (News:)
- Wakefield Show 2024 is next Saturday (News:)
- Git client updated to 0.07 (News:2)
- Archive Edition 27:1 reviewed (News:)
- Rougol April 2024 meeting on monday is Anniversary time (News:1)
Latest postings RSS Feeds
RSS 2.0 | 1.0 | 0.9
Atom 0.3
Misc RDF | CDF
 
View on Mastodon
@www.iconbar.com@rss-parrot.net
Site Search
 
Article archives
The Icon Bar: Programming: Database module for developers
 
  Database module for developers
  (13:13 28/10/2000)
  Matrix (10:12 30/10/2000)
    Gulli (14:58 15/6/2002)
      Matrix (08:37 6/11/2000)
  law (02:05 9/11/2000)
    Matrix (01:20 11/11/2000)
      law (12:10 11/11/2000)
    Gulli (14:58 15/6/2002)
      johnstlr (11:11 12/11/2000)
        Phlamethrower (11:53 27/11/2000)
          Gulli (18:17 27/11/2000)
            Phlamethrower (14:58 15/6/2002)
              Paolo Zaino (22:25 21/11/2001)
              Gulli (14:58 15/6/2002)
                Phlamethrower (14:58 15/6/2002)
        Guy (14:17 23/11/2001)
          Paolo Zaino (14:58 15/6/2002)
      Matrix (14:58 15/6/2002)
        Gulli (17:01 7/5/2001)
          ams (19:19 9/5/2001)
            Gulli (14:58 15/6/2002)
              ams (18:43 15/5/2001)
          Paolo Zaino (23:04 21/11/2001)
            Gulli (14:58 15/6/2002)
              Guy (14:58 15/6/2002)
 
Gulli Message #4650, posted at 13:13, 28/10/2000
Unregistered user Has anyone developed a database module that developers can buy to use for their own programs?

I want to write a small application that requires a database but instead of writing my own flat file database inside the application I'd prefer to use a module that would take care of the database related stuff like finding and returning the correct transaction, adding a transaction to the database and all that. That would leave me more time to write my application.

I'm not really interested in buying a full database program like S-Base to develop my application in - more like a module that I can talk to (SQL for example) and develop my program in C/C++, Basic or whatever.


[Edited by 172 at 13:14, 28/10/2000]

  ^[ Log in to reply ]
 
Matrix Message #4651, posted at 10:12, 30/10/2000, in reply to message #4650
Unregistered user There is an S.Q.L. version free for RISC OS?
  ^[ Log in to reply ]
 
Matrix Message #4653, posted at 08:37, 6/11/2000, in reply to message #4652
Unregistered user If you want we can try to build a S.Q.L. for RISC OS, there is also the PHP maker that is interessed to build it... it could be very very interesting and could help a lot RISC OS to grow and have new developers... today all is DATABASE! :-)
  ^[ Log in to reply ]
 
law Message #4654, posted at 02:05, 9/11/2000, in reply to message #4650
Unregistered user this might be what you're looking for :-
http://www.dse.nl/~topix/
or http://www.dnd.utwente.nl/topix/beta/tbase/index.html
  ^[ Log in to reply ]
 
Matrix Message #4655, posted at 01:20, 11/11/2000, in reply to message #4654
Unregistered user Well i tried to check this pages but there noone talk about S.Q.L. .... but thank you either and w will see....
  ^[ Log in to reply ]
 
law Message #4656, posted at 12:10, 11/11/2000, in reply to message #4655
Unregistered user
Well i tried to check this pages but there noone talk about S.Q.L. .... but thank you either and w will see....

Ah,
Sorry the link was aimed at Gunnlaugur's original request, but if it sparks a thought elsewhere as well, that'll be no bad thing.
  ^[ Log in to reply ]
 
johnstlr Message #4659, posted at 11:11, 12/11/2000, in reply to message #4657
Unregistered user I understand Gulli's need for a database module and why TBase is not suitable in this case. However on downloading TBase I immediately thought "this would make a really good module".

Perhaps it's worth emailing the authors and asking them. It would seem to me that there are two core header files that need to be exported as SWI calls (tbase.h and database.h I think). The rest appear to be internal data structures and the like. In general writing modules in C isn't that difficult - assuming they're using Acorn C of course.

Of course then module then has to cope with multiple databases, but from reading the docs is would appear to be able to do this already. In this case all the application needs is a handle to the database which could be passed in each SWI call.

  ^[ Log in to reply ]
 
Phlamethrower Message #4660, posted at 11:53, 27/11/2000, in reply to message #4659
Unregistered user When I get round to it I might do an 'abstract' database module, where each entry can be anything you like (text, number, reference to another entity, etc), which obviously involves little programming on my part and compatability with whatever you want. The only problem of course is that you'd have to be competent enough to handle all the references and things yourself, as well as adding any kind of user interface that's needed (e.g. for a WIMP database app).

It should be ready in a couple of days, when I get started of course.

  ^[ Log in to reply ]
 
Gulli Message #4661, posted at 18:17, 27/11/2000, in reply to message #4660
Unregistered user This is basically what I was looking for in the beginning! Relational database is not required for what I was thinking of so it can wait on my behalf. Just document the API/SWIs so writing a program using your module will not be too difficult.

SQL would be an optional extra or could even be written as a layer on top of this module? Probably better to have it relational first though?

  ^[ Log in to reply ]
 
Gulli Message #4665, posted at 17:01, 7/5/2001, in reply to message #4658
Unregistered user Paolo, do you know of any good books about writing a database program? I'm starting to see spare time in the near future and I'm still interested in getting my hands on a database program for RISC OS. I might use the TBaseLib but I also write it from scratch.
  ^[ Log in to reply ]
 
ams Message #4666, posted at 19:19, 9/5/2001, in reply to message #4665
Unregistered user
do you know of any good books about writing a database program? I'm starting to see spare time in the near future and I'm still interested in getting my hands on a database program for RISC OS. I might use the TBaseLib but I also write it from scratch.

Perhaps not quite directly useful, but if Gulli if you look into how Delphi (on the PC) addresses the abstract BDE (database engine) it might give you some ideas. I've been toying with the idea of creating a db module myself (not a line of code yet though!).

The sort of abstraction they use allow the user to address flatfiles or xBase (dBase, FoxBase) files as if they're SQL databases (you can even use SQL Selects and other commands on them !) or even apply a simple record based model to complex SQL database servers (like Interbase, Oracle or MS SQL Server). So whatever model suits you you can use (irrespective of the underlying database).

Very often you can just switch from a dbase style database (with SQL access) to a multiuser large scale database (like Oracle) with little or no additional programming.

Interestingly Borlands Interbase server has gone Open source !!! (I think its written in C++ so given the right compiler it could perhaps be ported to RISC OS (it already runs on Windows and Linux)).

Just a few ideas to mull over......

  ^[ Log in to reply ]
 
ams Message #4668, posted at 18:43, 15/5/2001, in reply to message #4667
Unregistered user Agreed. It is an omission which drove away Computer Concepts, Sibelius and no doubt others.
  ^[ Log in to reply ]
 
Paolo Zaino Message #4669, posted at 22:25, 21/11/2001, in reply to message #4662
Unregistered user Gunnlaugur: I've got no idea what SQL is, but I expect just about anything will be possible....


S.Q.L. (SEQUEL) was made by IBM in the '70. Its long name was Structured English Query Language (actually Structured Query Language).

S.Q.L. is a standard langauge for use datas recorded in relationals databases.

It was made from "relational databases" experiences and it is very easy to learn than many others query langauges.

Actually S.Q.L. is grow a lot then the first project and it is the most popular query language of the world (see My SQL, PostgreSQL, M.S. SQL Server, Oracle and more).<br><br>[Edited by Paolo Zaino at 23:06, 21/11/2001]

[Edited by Paolo Zaino at 23:07, 21/11/2001]

  ^[ Log in to reply ]
 
Paolo Zaino Message #4670, posted at 23:04, 21/11/2001, in reply to message #4665
Unregistered user Sorry if i didn't answer to your message Gunnlaugur, but my work give all my time actually, i try now if you accept my apollogize...

I am italian so i know italian books and i should make a search for know english versions of them...

Anyway i don't think that exsist "the complete manual for build a D.B.M.S." or maybe not...

  ^[ Log in to reply ]
 
Guy Message #4672, posted at 14:17, 23/11/2001, in reply to message #4659
Unregistered user
I understand Gulli's need for a database module and why TBase is not suitable in this case. However on downloading TBase I immediately thought "this would make a really good module".

Perhaps it's worth emailing the authors and asking them. It would seem to me that there are two core header files that need to be exported as SWI calls (tbase.h and database.h I think). The rest appear to be internal data structures and the like. In general writing modules in C isn't that difficult - assuming they're using Acorn C of course.

Sound idea imho.

For those with a few quiet minutes:
the database management system (DBMS) is often confused with the database itself. A database lives in one or more data files, and is relatively trivial to knock up. the DBMS sorts out file access, updates, searches and that kind of thing. if you have different kinds of data, you will need to split these up somehow and the dbms then handles complex queries for you - eg an sql interpreter and transaction logs. The heavyweight answer is the Relational dbms, but this a) is processor-intensive, b) needs much expertise to design-in and maintain data integrity (using primary keys and stuff), and c) is pretty complex in itself.

riscos is a lousy os for multi-user databases because it doesn't easily handle multiple user tasks. if that's important down the line, you might do better to run a web connection to a linux box running mysql or something, but i don't think there will be any relevant swi's ;(

  ^[ Log in to reply ]
 
Guy Message #4673, posted at 14:58, 15/6/2002, in reply to message #4671
Unregistered user
<blockquote>
Anyway i don't think that exsist "the complete manual for build a D.B.M.S." or maybe not...
</blockquote>

I don't want a complete manual anyway, something that explains the construction of the data storing and retrieving algorithms would be far more interesting smile

Relational theory was developed by E Codd and C J Date. Somebody called Boyce helped a bit too. Don't know if they talked much about the code design though. maybe a website for one of the open source databases would be a good place to look? eg mysql or postgresql

Cheers,
Guy

  ^[ Log in to reply ]
 
Paolo Zaino Message #4674, posted at 14:58, 15/6/2002, in reply to message #4672
Unregistered user Guy: Sound idea imho.
For those with a few quiet minutes:
the database management system (DBMS) is often confused with the database itself. A database lives in one or more data files....

I agree with Guy, to make a program for build Databases in S.Q.L. language is very easy, you need only to have a S.Q.L. internals book and you will make it faster (well i hope lol smile ).

the problem is the DBMS (the software who manage your databases).

As i always said in other parts of this forum:

a) RISC OS have not protected memory system so your datas will never have an high security level.

b) RISC OS have not multithread programming stuffs so it will be very hard to make a software who manage the D.B. connections by applications and users.

c) RISC OS is still not 32 bits , that means that anyD.B. will not be fast managed as a 32 BITS D.B.

d) Database world is joined with fast data storage world and till now i didn't see a Fast data storage on any RISC PCs; my RiscPC have Powertec 32 bits Ultra DMA SCSI card and it works at max 4 , 4.5 Mbytes for second....

what was possible to do on RISC OS is already done... (some desktop D.B. softwares just for study the D.B. world.)

BUT!!!! I STILL SAY THAT A.R.M. Processors can be very good in a professional kinds, i want remember that the new Strong A.R.M. is faster than a PENTIUM IV so please there is someone that want let this processors make their wonderfull work? (please someone say yes! cool )

[Edited by Paolo Zaino at 14:04, 25/11/2001]

  ^[ Log in to reply ]
 
Gulli Message #4671, posted at 14:58, 15/6/2002, in reply to message #4670
Unregistered user
Sorry if i didn't answer to your message Gunnlaugur, but my work give all my time actually, i try now if you accept my apollogize...

No worries Paolo, I have had much less time than I originally thought so I wouldn't have done anything about it anyway unhappy


I am italian so i know italian books and i should make a search for know english versions of them...

That would be good, my Italian isn't exactly worth mentioning smile


Anyway i don't think that exsist "the complete manual for build a D.B.M.S." or maybe not...

I don't want a complete manual anyway, something that explains the construction of the data storing and retrieving algorithms would be far more interesting smile

  ^[ Log in to reply ]
 
Gulli Message #4667, posted at 14:58, 15/6/2002, in reply to message #4666
Unregistered user
do you know of any good books about writing a database program? I'm starting to see spare time in the near future and I'm still interested in getting my hands on a database program for RISC OS. I might use the TBaseLib but I also write it from scratch.

Perhaps not quite directly useful, but if Gulli if you look into how Delphi (on the PC) addresses the abstract BDE (database engine) it might give you some ideas. I've been toying with the idea of creating a db module myself (not a line of code yet though!).

The sort of abstraction they use allow the user to address flatfiles or xBase (dBase, FoxBase) files as if they're SQL databases (you can even use SQL Selects and other commands on them !) or even apply a simple record based model to complex SQL database servers (like Interbase, Oracle or MS SQL Server). So whatever model suits you you can use (irrespective of the underlying database).

Very often you can just switch from a dbase style database (with SQL access) to a multiuser large scale database (like Oracle) with little or no additional programming.

That's something to think about. It might be a way to achive what I need.
If you do start making a db module please send me an e-mail as I may have a couple of ideas for what might be needed from that module and possibly be able to contribute something.

Interestingly Borlands Interbase server has gone Open source !!! (I think its written in C++ so given the right compiler it could perhaps be ported to RISC OS (it already runs on Windows and Linux)).

Yet again that dreaded C++ compiler problem! Anyone out there reading this? unhappy

[Edited by Gulli at 10:25, 10/5/2001]

  ^[ Log in to reply ]
 
Phlamethrower Message #4664, posted at 14:58, 15/6/2002, in reply to message #4663
Unregistered user
Problem (I may be misunderstanding you completely): If I was thinking of writing an application that could store it's entire data in memory I wouldn't really need the database module!

Ah. You are/were talking about large databases then (doh!). I have no plans whatsoever to include support for files being half in and half out of memory, since I myself would never need something like that (Note how everything here revolves around me smile)
You would be welcome to add that yourself of course, since the source will be freely available.
Also I would like to be able to assign the primary key myself (not use autonumber)

I expect I could do that, just by searching for an entry with your primary key and using that to look things up. It would just be a basic search facility (e.g. equals something exactly or bust), since the module will have no idea how to interpret the data itself. Later versions might have some understanding of it, it really depends on what I want to do with it.
Also remember that using the module's internal primary key's will speed things up for large databases, as well as avoid any duplication (although I expect people are competent enough to do that themselves).

  ^[ Log in to reply ]
 
Gulli Message #4663, posted at 14:58, 15/6/2002, in reply to message #4662
Unregistered user
I've got no idea what SQL is, but I expect just about anything will be possible.

Hmm, that's a bit discomforting to hear from someone who's about to write a database!

All the module would know would be the database reference (as a pointer to it in memory), an object reference (as a number which gets increased as each new object is added),

Problem (I may be misunderstanding you completely): If I was thinking of writing an application that could store it's entire data in memory I wouldn't really need the database module! Also I would like to be able to assign the primary key myself (not use autonumber)

field number (auto-increasing again), the length of the field (pre-defined or varying), and the actual data (just as a block of memory). Things like encryption and security might be supported at some stage, but for the first version I'll just leave it to the programmer.

I could knock up the reading code in a few minutes, but the main problem would be the memory management (keeping all internal pointers up to date). If it's urgently needed I could get it done and give you a copy (complete with source) by the end of the week (I think). If not, it really just depends on how I feel at the time monkey

No, I'm not in any hurry. I've just been thinking about writing a program that would require a simple database of some sort but I don't see that happening in the next three or four months.

172

  ^[ Log in to reply ]
 
Phlamethrower Message #4662, posted at 14:58, 15/6/2002, in reply to message #4661
Unregistered user I've got no idea what SQL is, but I expect just about anything will be possible. All the module would know would be the database reference (as a pointer to it in memory), an object reference (as a number which gets increased as each new object is added), field number (auto-increasing again), the length of the field (pre-defined or varying), and the actual data (just as a block of memory). Things like encryption and security might be supported at some stage, but for the first version I'll just leave it to the programmer.

I could knock up the reading code in a few minutes, but the main problem would be the memory management (keeping all internal pointers up to date). If it's urgently needed I could get it done and give you a copy (complete with source) by the end of the week (I think). If not, it really just depends on how I feel at the time monkey

  ^[ Log in to reply ]
 
Matrix Message #4658, posted at 14:58, 15/6/2002, in reply to message #4657
Unregistered user Make an interpret for S.Q.L. with a DB library is not hard in the end S.Q.L. is a "ensembles" management system , this mean that it have a different approact to the data , different by all others languages like C etc... that have to scroll pointers for find the data that you need, it manage an "ensemble" of data reguled by bills that you decide so you can obtain your data from this "questioning" language.... etc...

But for the server side? eheheh that's is the most big problem... if we try to implement it people will love to use it with (for example) PHP language for build internet sites, or in a LAN for share databases or manage informations etc... (well i'm still studing this so for now is better to no dream too far for me!) ehehehe smile

  ^[ Log in to reply ]
 
Gulli Message #4657, posted at 14:58, 15/6/2002, in reply to message #4654
Unregistered user Dave:
The TBase looks and sounds very interesting but isn't exactly what I was looking for - it's a library that I would have to include in my own program and therefore limit my (and others) chances of writing a shareware product that could use the database.

What I'm looking for is a database program/module that I can talk to with SWIs, not compiling it inside my own program. Something I could either include in a distribution or advice people on where to get it. I know this could be a bit risky since RISC OS software quite often seems to disappear as soon as it's released but I think that with a few applications relying on it, it's more likely to stay there.

Paolo:
I'm VERY interested in participating in making an SQL database for RISC OS but at the moment I hardly have enough time for both work and school so I would probably not be of much use until next summer.
If, however, you start writing one I'll be more than happy to take part in it. I hardly know anything about database programming, which is why I was looking for one in the first place, but one can always learn one more thing smile

Maybe an SQL Database can be built using the Tbase lib? Tbase really looks fast on my SA RiscPC.

172


[Edited by 172 at 12:19, 11/11/2000]

  ^[ Log in to reply ]
 
Gulli Message #4652, posted at 14:58, 15/6/2002, in reply to message #4651
Unregistered user Not that I know of!

I was hoping someone has written a module that anyone could use - for a price of course. In my opinion this could seriously boost application development for RISC OS. I'd do it myself if I just knew how or had the time to learn to. Maybe I'll have time next July though smile

  ^[ Log in to reply ]
 

The Icon Bar: Programming: Database module for developers