SRL Archive - Suggestions

Support for SQL


superuser

2011-03-21 02:36:45

Cheers,

Just thinking how awesome it would be if there was support for different SQL-engine APIs. MySQL, PostgreSQL or even embedded one (SQLite3) would be very nice.

The benefits are obvious. For instance, this would allow some really sophisticated antibans.

Sex

2011-03-21 02:49:32

You can create one :p.

TomTuff

2011-03-21 02:52:05

The benefits aren't so obvious to me, what sort of antiban would you be able to do?

Sex

2011-03-21 03:08:40

Bro, you can write a php script or something to do this..

Edit: For MySQL. That's all I'm familiar with :P.

nielsie95

2011-03-21 04:04:48

Yes, it would be nice, although the RS advantages aren't that clear to me either.

Wizzup?

2011-03-21 04:30:56

It is possible, just slightly annoying in a statically typed language I suppose. SQLite would be nice.

nielsie95

2011-03-21 04:45:59

Not that annoying..?
http://wiki.lazarus.freepascal.org/Lazarus_Database_Tutorial

superuser

2011-03-21 09:35:10

From: TomTuff
The benefits aren't so obvious to me, what sort of antiban would you be able to do?


You can easily keep track of peoples inquiries regarding "are u a bot", "mining lvls" or even trade requests in order them to bust you.
For example if player trades you and you can see from your db that he/she has requested that five times in the last couple of minutes, you can reply something like "dude, stop that already". You can even add a bit of history to your decision logic like if the player has been trying to bust you numerous times in the last weeks, reply something else.
If you do this traditionally, it'll end up as a lots of lines of code bloat.

Just use your imagination, there's a lot of uses for databases :)

superuser

2011-03-21 09:36:50

From: Sex
Bro, you can write a php script or something to do this..

Edit: For MySQL. That's all I'm familiar with :P.


Yes, this is possible, but utterly stupid way of achieving this ;) You need to install Apache (or IIS) and PHP separately.

Sex

2011-03-21 10:14:17

I know. But I'm a noob and php and Simba/Pascal is pretty much all I know :p.
And ew, IIS..

Anyways, I'm sure you can make a module for Simba to do this yourself and come out with a PoC for us to look through :p. If it's cool I'm sure Wizzup or someone will add it.

Wizzup?

2011-03-21 11:31:06

Well, it is indeed very useful for auto responders.

Nielsie, note that I said slightly annoying. ;) But it's certainly possible.

moparisthebest

2011-03-24 14:47:56

Sqlite would be great, not so sure about the rest of them, since they require a server. But anyway, surely this is something that should be in a plugin instead of in the Simba core, and you can already write it in a plugin.

pyroryan

2011-03-24 15:02:53

From: moparisthebest
Sqlite would be great, not so sure about the rest of them, since they require a server.


Yea I personally use sqlite for my GE price history database, its awesome :).