Dear Marie,
thanks for sending the access information to your site. I made an exhaustive (exhausting!) study of what was happening on your server and my conclusion is that you should ask your
host to upgrade to PHP 5.1.4. The details of how I reached this conclusion appear below.
The exact point of the critical failure of your install occurs is way down in the database access code, in "lib/adodb/drivers", when Moodle is trying to find out the structure of the of the "mdl_context" table. Moodle uses PHP's "mysql_fetch_field" function to get this information. The function returns an array of information about the table. Unfortunately, on your site the information that is returned indicates that the "contextlevel" and "instanceid" fields in the "context" table are
date fields when they are actually
integer fields. I have no idea why this is, but for some reason PHP and MySQL are getting their wires crossed (figuratively speaking) on your server.
Now it so happens that just this morning I was fixing somebody else's Moodle on the same host. Curiously enough, that install on the other site worked without a hitch!
I checked the server specifications of the two sites and noticed that while your site is using PHP 4.4.1, the other site is using PHP 5.1.4. Therefore I suggest you ask your
webhost to upgrade you to PHP 5.1.4
I'm afraid I cannot offer a "workaround" for this problem, because it is too fundamental. The "FetchField" function in "lib/adodb/drivers/adodb-mysql.inc.php" is used ALL the time by Moodle, and on your site it often returns faulty information about integer fields. That is why the original error about adding capabilities occurred and it is also why other errors such as "A problem occurred inserting current version into databases" happen later on in the attempted install.
I haven't fixed your problem, but if you can persuade your hosting company to upgrade your PHP to 5.1.4 (as they have done for at least one other customer) then I am confident your install will succeed.
best regards
Gordon
========================
result of $db->MetaColumns('mdl_context'): note the "type" setting of "contextlevel" and "instanceid" are "datetime" and "date" respectively
========================
Array
(
[0] => stdClass Object
(
[name] => id
[table] => id
[def] => mdl_17
[max_length] => 170750208
[not_null] => 0
[primary_key] => 1
[multiple_key] => 1
[unique_key] => 0
[numeric] => 1
[blob] => 0
[type] => int
[unsigned] => 0
[zerofill] => 0
[binary] =>
)
[1] => stdClass Object
(
[name] => contextlevel
[table] => contextlevel
[def] => mdl_17
[max_length] => 170750280
[not_null] => 0
[primary_key] => 1
[multiple_key] => 1
[unique_key] => 0
[numeric] => 0
[blob] => 0
[type] => datetime
[unsigned] => 0
[zerofill] => 0
[binary] =>
)
[2] => stdClass Object
(
[name] => instanceid
[table] => instanceid
[def] => mdl_17
[max_length] => 170750368
[not_null] => 0
[primary_key] => 1
[multiple_key] => 1
[unique_key] => 0
[numeric] => 0
[blob] => 0
[type] => date
[unsigned] => 0
[zerofill] => 0
[binary] =>
)
)