[development] Extend database abstraction layer, to include table creation.

Fehér János feher.janos at mindworks.hu
Tue May 16 06:10:43 UTC 2006


2006.  május 13, szombat 16.04 dátummal Jeremy Epstein ezt írta:
> Fact (as you said): new Drupal developers just want to write code that
> works, and they don't care about portability. So the only way that

The newbies only want a good documentation and examples in one place.
Yesterday, I try to look for taxonomy_save_term's documentation. There's
no a word about this function. Ok, experienced users are able to look
inside the code to find out how it works, but I don't think that it
is the best way. Newbies love to write perfect code, but if we don't
learn them how they can do it and we force them, they'll be upset.

> I don't see this as being any different from the learning barrier that
> already exists to support table prefixing. New developers must learn
> the {curly bracket} syntax before they start writing any SQL in Drupal

Should they read and memorize the whole Drupal Handbook to write a code?
I don't think so. Did you know, the {} is only (i don't know, because when
I type "curly" into the search box, I get issues, forum topic, etc but not
the handbook pages) mentioned in the "How to write database independent 
code" . It's not about how to write db independent code. When I run through 
the table of contents of the handbooks, I don't see any section dedicated to 
how to use the db functions properly.

I think, if you force the users to use special functions, you have to give
them sophisticated documentation, where you tell them how and why they
should use, with detailed use cases. You can't write too much.

Good practice: "Multipage forms with the Forms 
API" (http://drupal.org/node/54753) It's a detailed tutorial with
a huge code and description. 

Bests,
--
Aries


More information about the development mailing list