Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2008-12-26 16:08:38

loid
Member
Registered: 2005-03-09
Posts: 38

[resolved] Unknown column 'load_order' - can't install 4.0.7

I was able to find a brief discussion about this problem in the 4.0.7 feedback forum, but that’s been closed and I never saw a solution.

When I tried to upgrade today from 4.0.6 to 4.0.7 I got an error line including “Warning: Unknown column ‘load_order’ in ‘order clause’ select name, code, version from txp_plugin where status = 1 AND type IN (1,3) order by load_order in /textpattern/lib/txplib_db.php..”

and then when I went to my admin plugin page it showed no plugin info, just this error:

Warning: Unknown column ‘load_order’ in ‘field list’ select name, status, author, author_uri, version, description, length(help) as help, abs(strcmp(md5(code),code_md5)) as modified, load_order from txp_plugin where 1 order by name asc in /textpattern/lib/txplib_db.php..”

I have given up and re-installed v 4.0.6

Does anyone have information on this issue and how I can solve it and move forward with the upgrade?

Offline

#2 2008-12-26 17:32:25

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,323
Website Mastodon

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

This column should have been added automatically to your database during the upgrade procedure. If, for whatever reason, this automatism didn’t do its duties, you can force the upgrade procedure to run once again by executing these steps:

- Upload all of Textpattern 4.0.7 once again. Do not log in.

- Issue these SQL command in phpMyAdmin (assuming your table prefix is empty):

UPDATE txp_prefs SET val='4.0.6' WHERE name='version'; 
UPDATE txp_prefs SET val=0 WHERE name='dbupdatetime'; 

- Log in to the admin side. You should be pushed to the “Languages” preferences then.

Offline

#3 2008-12-28 08:20:46

tore
Member
From: Tväråmark, Sweden
Registered: 2006-11-08
Posts: 26

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

Having had the same problem without being able to resolve it, I found by testing in phpMyAdmin that to add a column ‘load_order’ to the ‘txp_plugins’ table was not successful, ending in error ‘#1142 – ALTER command denied to user …’ (thanks Ruud for the hint!). I have contacted my webhost asking for ALTER permission hoping that will help!

Yes, my webhost admitted the lacking ALTER permission, used as default(!) but not any longer. Well this helped so far as to the upgrade without error, but …

NO, I cannot see any pages, all links to articles show blank pages! All seems totally corrupt!

Any hint how to proceed? Did my former attempts to upgrade degenerate something? Are there some tags that may work differently, or what???

—- later —-

Now I have erased both the Textpattern files and the database tables and uploaded both of the previous version, with success!!
My site is now in full function using version 4.0.6 like before my upgrade attempt.

Now please, can anybody tell (or guess) wether all difficulties may have been generated solely from the lack of ALTER permission initially, or if there may be some further precautions to be recommended — so I finally may dare to try that upgrade again? Since I would like to ….

Thanks now and on beforehand for kind hints and advices (were by mail, told above)!

P.S. Btw, what does this mean: ‘Check tables’ tells there are problems in indexing, typically that “PRIMARY and INDEX keys …” may not both be set for the `name` column, for five tables: txp_form, txp_lang, txp_page, txp_plugin and txp_section. What’s that?

Last edited by tore (2008-12-28 12:50:38)

Offline

#4 2008-12-28 12:40:57

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

Wait for ALTER permission, then try again (or wait a week or two for 4.0.8). If you have plugins installed, you may also want to check if there are newer versions of those plugins available (for 4.0.7).

Offline

#5 2008-12-28 16:16:38

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

If you do have ALTER permission and no longer have any error messages in TXP itself, change production status to ‘debug’ in the preferences and check the HTML source of the page that doesn’t render correctly. At the bottom, you’ll see how TXP parses the tags. Could be a typo in a template.

Offline

#6 2009-02-28 20:56:28

tore
Member
From: Tväråmark, Sweden
Registered: 2006-11-08
Posts: 26

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

Hello all — back again now decided to upgrade to 4.0.8. The webhost now has set ALTER permission, so let’s go.

Pages invisible after upgrade to 4.0.8

The upgrading from 4.0.6 to 4.0.8 seemed to work extremely well and the first logon put me at the language tab as foreseen. Also, after removing the install catalog the validation succeded. The first attempt to see a real page was OK, but I realise that it was probably just a casched one …

Most of the menu bar will show up and function virtually, but the page content never shows up. I have put the URLs into messy mode and removed the .htaccess in order to eliminate some possible sources of error. Also, I have checked the database for the new load_order column in the _txp_plugin table, and it exists (the table is empty, though, since I use no plug-ins).

Further I have looked into phpMyAdmin and the site logs but cannot find something unusual, as far as I understand.

Next is to set ‘debug status’ and see what comes out (well, anybody may test now, until I find a solution at http://tores.se/toretank). I have tried to interpret this output (from clicking the uppermost side-bar link, as an example). Since the txp:popup tag is especially mentioned I tried to remove it and the main difference was that the top-page-text disappeared from the empty page.

This must be some simple thing that kills most functionality in the page tags, but I have not the knowledge how to investigate it without at least an advice, where to begin? Thanks very much in advance — here is the debug output:

AT THE TOP OF THE RENDERED PAGE:
<txp:popup type="c" this_section=1 label="Ämne &ndash; inget&nbsp;=&nbsp;alla:"  wraptag="p" /> ->  Textpattern Warning:   on line 916

textpattern/lib/txplib_misc.php:916 trigger_error()
textpattern/publish.php:1090 splat()
textpattern/publish.php:1012 processtags()
textpattern/publish.php:496 parse()
index.php:33 textpattern()

AT THE BOTTOM OF ITS SOURCE CODE:
<!-- Runtime:    0,2509 -->
<!-- Query time: 0,236491 -->
<!-- Queries: 14 -->
<!-- Memory: 2021Kb, <txp:recent_articles section="datorbruk" limit="5" label="" wraptag="p" /> -->

<!-- txp tag trace: 
[SQL (0,0202071666718): select name, data from text_txp_lang as txp_lang where lang='sv-se' AND ( event='public' OR event='common')]
[SQL (0,00014591217041): select name, code, version from text_txp_plugin as txp_plugin where status = 1 AND type IN (0,1) order by load_order]
[SQL (0,0137531757355): select page, css from text_txp_section as txp_section where name = 'default' limit 1]
... (etc.)
<txp:recent_articles section="datorbruk" limit="5" label="" wraptag="p" />
	[SQL (0,0359230041504): select *, id as thisid, unix_timestamp(Posted) as posted from text_textpattern as textpattern where Status = 4  and Section IN ('datorbruk')  and Posted <= now() and (now() <= Expires or Expires = '0000-00-00 00:00:00')  order by Posted desc limit 0,5]
[ ~~~ secondpass ~~~ ]
 -->

Last edited by tore (2009-03-01 07:05:08)

Offline

#7 2009-02-28 23:56:32

graeme
Plugin Author
Registered: 2004-06-21
Posts: 337
Website

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

tore wrote:

<txp:popup type=“c” this_section=1 label=“Ämne &ndash; inget&nbsp;=&nbsp;alla:” wraptag=“p” />

Make sure you quote all of your attributes. this_section="1"

Offline

#8 2009-03-01 07:30:56

tore
Member
From: Tväråmark, Sweden
Registered: 2006-11-08
Posts: 26

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

Thanks for that hint, graeme!

After

  • correcting =1 to =“1” in several places,
  • correcting a malformed <txp:else /> tag, and
  • changing a so far functional <txp:message /> into the valid form <txp:comment_message />

all functions normally again!

Running in debug mode was very helpful, since noting where about in the page rendering the debug output stopped helped to localise the next error.

These last versions apparenly tolerate less sloppy code than did 8.0.6!

Thanks for advices and help!

Tore

Offline

#9 2009-03-01 15:48:43

tore
Member
From: Tväråmark, Sweden
Registered: 2006-11-08
Posts: 26

Re: [resolved] Unknown column 'load_order' - can't install 4.0.7

Addendum:

In order to be able to upload and maintain files in TXPs file catalog I had to make about the following adjustments in the database,

ALTER TABLE `text_txp_file`
 ADD `size` INT AFTER `downloads` ,
 ADD `created` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' AFTER `size` ,
 ADD `modified` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' AFTER `created` ,
 ADD `status` SMALLINT NOT NULL AFTER `modified` ;

since those columns were missing, though apparenly should have been added at upgrade (why did it fail?).

The details like data type etc. are my guesses and partly occasional.

Would anyone please kindly check that it conforms with what TXP can use in the long run?

Tore

Offline

Board footer

Powered by FluxBB