Thread: Re: [HACKERS] Where do they find the time??? Great Bridge

Re: [HACKERS] Where do they find the time??? Great Bridge

From
Justin Clift
Date:
Christopher Kings-Lynne wrote:
>
> > What a coincidence.  I was about to say the exact opposite.  Obviously,
> > PostgreSQL isn't the one true database and everyone should Jump
> > into MySQL.
> > It is easier to type.
> >
> > I hope your post was meant as a joke because it was hilarious.
>
> These days MySQL is less of a database and more of an SQL interface to about
> 10 different database backend products...

On that note, maybe we should write a wrapper function so it becomes a
frontend interface for PostgreSQL!

;-)

+ Justin

>
> Chris
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
     - Indira Gandhi

Re: [HACKERS] Where do they find the time??? Great

From
Charles Tassell
Date:
Heh, don't laugh.  That would actually be a great product, considering all those pre-written PHP and PERL scripts for MySQL.  I'm the SysAdmin of an ISP, and I have  a lot of conversations with our web clients like:

Do you support MySQL?

No, we use Postgres, it's got better features.

Yeah, but I found this script on the web, but it only supports MySQL, and I'm to lazy/stupid/cheap to convert it to Postgres.

Of course, I'm too lazy/cheap to admin two different database servers, so the clients are out of luck unless they want to pay extra for MySQL (no one has as of yet).


At 12:25 AM 9/17/01, Justin Clift wrote:
Christopher Kings-Lynne wrote:
[snip]
> These days MySQL is less of a database and more of an SQL interface to about
> 10 different database backend products...

On that note, maybe we should write a wrapper function so it becomes a
frontend interface for PostgreSQL!

;-)

+ Justin

>
> Chris
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
     - Indira Gandhi

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/users-lounge/docs/faq.html

Re: [HACKERS] Where do they find the time??? GreatBridge

From
Justin Clift
Date:
I wonder if it would really be possible to do?

+ Justin


Charles Tassell wrote:
>
> Heh, don't laugh.  That would actually be a great product, considering
> all those pre-written PHP and PERL scripts for MySQL.  I'm the
> SysAdmin of an ISP, and I have  a lot of conversations with our web
> clients like:
>
> Do you support MySQL?
>
> No, we use Postgres, it's got better features.
>
> Yeah, but I found this script on the web, but it only supports MySQL,
> and I'm to lazy/stupid/cheap to convert it to Postgres.
>
> Of course, I'm too lazy/cheap to admin two different database servers,
> so the clients are out of luck unless they want to pay extra for MySQL
> (no one has as of yet).
>
> At 12:25 AM 9/17/01, Justin Clift wrote:
>
> > Christopher Kings-Lynne wrote:
> > [snip]
> > > These days MySQL is less of a database and more of an SQL
> > interface to about
> > > 10 different database backend products...
> >
> > On that note, maybe we should write a wrapper function so it becomes
> > a
> > frontend interface for PostgreSQL!
> >
> > ;-)
> >
> > + Justin
> >
> > >
> > > Chris
> > >
> > > ---------------------------(end of
> > broadcast)---------------------------
> > > TIP 1: subscribe and unsubscribe commands go to
> > majordomo@postgresql.org
> >
> > --
> > "My grandfather once told me that there are two kinds of people:
> > those
> > who work and those who take the credit. He told me to try to be in
> > the
> > first group; there was less competition there."
> >      - Indira Gandhi
> >
> > ---------------------------(end of
> > broadcast)---------------------------
> > TIP 5: Have you checked our extensive FAQ?
> >
> > http://www.postgresql.org/users-lounge/docs/faq.html

--
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
     - Indira Gandhi

Hey,

>I wonder if it would really be possible to do?

Sure is.

For php there's Pear (or I've written a DB wrapper, easily changed for
databases)
Perl - already has DBI / DBD, no point redoing that.
Python - no idea, never used it.

The dumps would be a bit different but, something to work on.

Of course, it depends on the script you're looking at, whether it's worth
re-writing from scratch or trying to convert it.


-----------------
      Chris Smith
http://www.squiz.net/


Re: [HACKERS] Where do they find the time??? GreatBridge

From
Martijn van Oosterhout
Date:
On Mon, Sep 17, 2001 at 02:51:10PM +1000, Justin Clift wrote:
> I wonder if it would really be possible to do?

Well, it seems to me you could do it at serveral levels:

1. Have a proxy running on whatever port MySQL uses that simply translates
the queries coming in and emulates the protocol. Problem is, you'd have to
possibly translate function names, etc. I don't think there'd be any real
SQL constructs they support be we don't. You can always ignore anything not
supported unless it really has a material effect.

2. Support multiple grammers, configurable by database. Then you could
support:

CREATE DATABASE dummy EMULATING mysql;

Create a table of all the functions in mysql with a loadable module that
defines them all. Would make lots of people *really* happy. You could
emulate every database under the sun. That'd be an excellent marketing
point.

"PostgreSQL is much more powerful then MySQL. It even has an emulation mode
so all your existing MySQL programs will run without changes."

The thing is, I don't even think this would be too hard to do. A bit of time
to setup maybe. You could define a function pg_parser which is the parser
for this database.

Oh, you'd also have to support different client communication protocols. I
have no idea how hard that would be.

Would also need to provide a per connection override so that psql and
pg_dump could be used without having to rewrite them.

3. Similar to proxy but built into the database. Don't like this. Too many
levels of parsing. Seems the wrong place.

4. Supply a MySQL perl module that does the converting. Maybe be easy to do
but only covers one application at a time. More robust as a separate
application but would probably have to do complete parsing to give complete
support.

Probably others but I can't think of any right now.

--
Martijn van Oosterhout <kleptog@svana.org>
http://svana.org/kleptog/
> Magnetism, electricity and motion are like a three-for-two special offer:
> if you have two of them, the third one comes free.