9 2185
"Ruby Tuesday" <ru**********@y ahoo.com> wrote in message news:<c0******* ******@ID-205437.news.uni-berlin.de>... Which one is better to do dynamic websites using MySQL? Thanks
a.. ADODB, http://php.weblogs.com/ADOdb/ b.. Metabase, http://www.phpclasses.org/browse.html/package/20.html c.. PEAR::DB, http://pear.php.net/manual/en/core.db.php d.. PHPLib database wrappers, http://sourceforge.net/projects/phplib
In the company I work for, we're preparing some framework for our
projects. When we tried the above, we find that they all go for "too
much" abstraction---which is somewhat messy. Say for example, they
check the choosen DB and then use the appropriate function for that
DB.
If you like procedural style, you better to go for
<http://in2.php.net/dbx>
For us, we decided to go for our simple abstraction so that when
to switch to another DB, just it is enough to touch the class alone.
Example:
class DB
{
//var ...
function DB() ///constructor
{
///...
}
function dbConnect()
{
mysql_connect() ; // or pg_connect(); or whatever
//...
}
function dbClose()
{
mysql_close(); // or pg_close(); or something else
//...
}
function dbQuery()
{
mysql_query();
//...
}
function dbFetchArray()
{
mysql_fetch_arr ay();
//...
}
function dbGetError()
{
mysql_error();
}
function dbGetErrno()
{
mysql_errno();
}
}
--
"Success = 10% sweat + 90% tears"
If you live in USA, please support John Edwards.
Email: rrjanbiah-at-Y!com
Ruby Tuesday wrote: Which one is better to do dynamic websites using MySQL? Thanks
a.. ADODB, http://php.weblogs.com/ADOdb/ b.. Metabase, http://www.phpclasses.org/browse.html/package/20.html c.. PEAR::DB, http://pear.php.net/manual/en/core.db.php d.. PHPLib database wrappers, http://sourceforge.net/projects/phplib
We have had outstanding success with the ADODB package for our JAYA123
order-entry, invoicing web-service ( http://www.jaya123.com). We tried the
fist three and thought all did a good job, were fast, easy to use, simple to
install, etc. We chose ADODB because it had some classes that allowed syntax
that was similar to how Microsoft Jet is coded and we have a lot of
experience on that platform from past lives, so our learning curve was a bit
flatter. I highly recommend ADODB, but the others are fine as well. I think
it will come down to personal preference. Try them all... there is no wrong
answer here IMO. YMMV.
Al Canton, Vice President
Adams-Blake Company, Inc.
***
JAYA123 - the new web-based total-office system for the
small biz. Order entry, billing, bookkeeping, etc. for $14.95
a month. Everyone says "It's cool as a moose!!"
See why at: http://www.jaya123.com
***
In my case they provide too little abstraction. I wanted to isolate the
database, queries et al, completely from the application code. For my own
abstraction layer, it was more straight forward to call the PHP functions
directly.
Uzytkownik "R. Rajesh Jeba Anbiah" <ng**********@r ediffmail.com> napisal w
wiadomosci news:ab******** *************** ***@posting.goo gle.com... "Ruby Tuesday" <ru**********@y ahoo.com> wrote in message
news:<c0******* ******@ID-205437.news.uni-berlin.de>... Which one is better to do dynamic websites using MySQL? Thanks
a.. ADODB, http://php.weblogs.com/ADOdb/ b.. Metabase, http://www.phpclasses.org/browse.html/package/20.html c.. PEAR::DB, http://pear.php.net/manual/en/core.db.php d.. PHPLib database wrappers, http://sourceforge.net/projects/phplib
In the company I work for, we're preparing some framework for our projects. When we tried the above, we find that they all go for "too much" abstraction---which is somewhat messy. Say for example, they check the choosen DB and then use the appropriate function for that DB.
If you like procedural style, you better to go for <http://in2.php.net/dbx>
For us, we decided to go for our simple abstraction so that when to switch to another DB, just it is enough to touch the class alone.
Example:
class DB { //var ... function DB() ///constructor { ///... } function dbConnect() { mysql_connect() ; // or pg_connect(); or whatever //... } function dbClose() { mysql_close(); // or pg_close(); or something else //... } function dbQuery() { mysql_query(); //... } function dbFetchArray() { mysql_fetch_arr ay(); //... } function dbGetError() { mysql_error(); } function dbGetErrno() { mysql_errno(); } }
-- "Success = 10% sweat + 90% tears" If you live in USA, please support John Edwards. Email: rrjanbiah-at-Y!com
Hello,
On 02/16/2004 03:26 AM, Ruby Tuesday wrote: Thanks to all. Perhaps anyone can narrow it down to just one or two selection where I can do the following easily:
- database search, add, replace, edit .. - database paging of the result set - have a nice(don't have to be fancy) forms display - easily maintain - less coding etc
I think you want something that goes beyhond just database abstraction.
You may want to try Metastorage. This is a tool that will generate data
access object classes from a simple data model definition. It wraps you
database tables into classes as if the your table rows were objects of
those classes.
Metastorage also generates classes that installs the database schema for
you as well generate forms that handle common types of manipulations
like creating new objects (table row entries).
Forms presentation is defined from themes that can be chosen from a
pre-defined selection that makes your Web forms look like familiar
desktop OS applications or you can design your own with your templates.
As a bonus, it generates nice UML class diagrams to let you make a good
impression your boss or your clients.
Take a look at the screenshots here: http://www.meta-language.net/screenshots.html
Find all about Metastorage here: http://www.meta-language.net/metastorage.html
--
Regards,
Manuel Lemos
PHP Classes - Free ready to use OOP components written in PHP http://www.phpclasses.org/
PHP Reviews - Reviews of PHP books and other products http://www.phpclasses.org/reviews/
Metastorage - Data object relational mapping layer generator http://www.meta-language.net/metastorage.html
With total disregard for any kind of safety measures "Ruby
Tuesday" <ru**********@y ahoo.com> leapt forth and uttered: Thanks to all. Perhaps anyone can narrow it down to just one or two selection where I can do the following easily:
- database search, add, replace, edit .. - database paging of the result set - have a nice(don't have to be fancy) forms display - easily maintain - less coding etc
Thanks
For those kind of features it might be worth checking out the Web
Application Component Toolkit project http://wact.sourceforge.net/
It features some nice database abstraction, provides a
compatibility layer for both PEAR::DB and ADODB, has a Paging
feature and has a very cool template engine. You can implement a
paged recordset with only a few lines of PHP code.
--
Phil Roberts | Nobody In Particular | http://www.flatnet.net/ This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: lawrence |
last post by:
A user writes this sentence: "It was the New Urbanist's nightmare of
sprawl run amok."
They input that and my PHP script hits it with addslashes() and then
the sentence gets put in the database. A slash is likely inserted in
front of the quote mark in "Urbanist's".
Later the user runs a search of the database for "New Urbanist's
nightmare".
|
by: Rainer Collet |
last post by:
hi!
i tested several php database abstraction layers (db, mdb(2), creole,
adodb, etc), but i always missed one really important feature:
i need a method for a limited select which gives me the resultset and
the total number of rows the select would have returned without the
limit.
nativly this is very easy
SELECT SQL_CALC_FOUND ROWS * FROM table LIMIT 0,10 in mysql for
example.
|
by: SectorUnknown |
last post by:
I've written a database (Access mdb) front-end using Python/wxpython/and
ADO. However, the scope of the project has changed and I need to access
the same data on an MSSQL server. Also, the front-end needs to be cross-
platform (Windows and Linux).
Does anyone have any suggestions on what database connectivity I should
use? I've looked at mxODBC and wxODBC briefly, but am not sure what is
the best way to go.
BTW, although I would love...
|
by: David |
last post by:
Is there a good DataBase Abstraction layer that will handle the
mySql, Sql Server, and MS Access engines? I do not wish to write the
same functions with the three different PHP db functions.
I see that php_dba is listed as an extension, but I determine which
DBs are supported. However, I think that it does not support the ones
I need.
Thanks
|
by: Brett |
last post by:
If I want to easily swap the database I'm using, what is the best method for
developing that tier in my application?
I'll have basically a 4 tier app:
1. presentation
2. business logic
3. data layer containing standard SQL compliant queries
4. any database
I'm looking for the most efficient way to design tier 3. I can't use stored
| |
by: DartmanX |
last post by:
I'm looking for any comparisons of PHP Database Abstraction Layers out
there, with an eye towards speed/efficiency. I'm still using PEAR::DB,
which obviously leaves something to be desired.
I'm at a point now where I can look at switching to a better system.
Jason
|
by: Colin McKinnon |
last post by:
Hi all,
There's lots of DB abstraction layers out there, but a quick look around
them hasn't turned up anything which seems to met my requirements. Before I
go off and write one I thought I'd ask here if anyone knows of such a
beast...
I want some code where I present an array of data, and the corresponding
primary key and let the code work out whether to INSERT or UPDATE it, I
also want to be able to present the data from a QBF or...
|
by: rickycornell |
last post by:
Greetings All,
On past projects in PHP4 I had always just written my own libraries to
deal with database interaction. Somehow I was operating in the dark
that there were all these database abstraction things available that
made my work on the libraries I made from scratch a waste of time.
So now I've started researching all these things that are available,
and I have to say I am a little confused. It's a matter of
understanding the...
|
by: Ivan S |
last post by:
What are your recommendations for lightweight database abstraction
library (Oracle/MySQL)?
I prefer OOP. :)
Tnx, Ivan.
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |