OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



PostgreSQL DB Error for login after 1 day logout...

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

PostgreSQL DB Error for login after 1 day logout...

Postby victorp » Mon Feb 03, 2014 8:23 pm

I have this error message occurring twice on me:

DB Error: ERROR: syntax error at or near "ORDER" LINE 3: ORDER BY day DESC ^

after I have logged out but left the web page as it is in my web browser until the following days. Once when I used the side bar login panel with my user credential after clicking LOGIN, and the other time when I click the LOGIN link on the navigation bar.

When the above happens, I just visit the base URL to login from there. It seems like a stale SSID problem.

My OJS is v2.4.3 running on Mac OS X 10.8.5 with PHP v5.3.26, Apache HTTP v2.2.24 and PostgreSQL 9.2.4.
victorp
 
Posts: 9
Joined: Sun Jan 26, 2014 8:06 am
Location: Singapore

Re: PostgreSQL DB Error for login after 1 day logout...

Postby asmecher » Tue Feb 04, 2014 9:34 am

Hi victorp,

It looks like some SQL made it into the release that PostgreSQL doesn't support; I've filed this at http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8549. Feel free to CC yourself to the entry so you'll be notified when it changes.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 9210
Joined: Wed Aug 10, 2005 12:56 pm

Re: PostgreSQL DB Error for login after 1 day logout...

Postby victorp » Wed Apr 23, 2014 6:14 am

Does this patch at https://github.com/pkp/ojs/commit/fb069 ... 55549.diff resolves this issue as well?

Also, do I need to modify the table usage_stats_temporary_records as I don't see the field entry_time in the table? (I see a field metric in the table which I assume is being used somewhere else.)

In addition, in the schema.xml, the field entry_time is listed last after the field file_type whereas the code to manipulate the field entry_time is between the field day and country_id. Are these correct as they are?
victorp
 
Posts: 9
Joined: Sun Jan 26, 2014 8:06 am
Location: Singapore

Re: PostgreSQL DB Error for login after 1 day logout...

Postby bbeghelli » Tue Apr 29, 2014 7:32 am

Hi Victorp,

Did you manage to fix this? Related to your questions previously, you just need to apply the patch in question and run an upgrade using the upgrade tool, something like this: php tools/upgrade.php upgrade

So the usage_stats_temporary_records table will get update automatically.

Thanks,
Bruno
bbeghelli
 
Posts: 152
Joined: Tue Jun 25, 2013 2:22 pm

Re: PostgreSQL DB Error for login after 1 day logout...

Postby victorp » Thu May 01, 2014 2:33 am

Dear Bruno,

Yes, I did manage to patch OJS and run the DB upgrade tool. Overall, it seems to resolve this issue.

By the way, I have to manually disable the "Null" flag for the field "entry_time" even though the schema.xml file has declared the field NOTNULL. It must be something on my particular setup - unsure though.
victorp
 
Posts: 9
Joined: Sun Jan 26, 2014 8:06 am
Location: Singapore


Return to OJS Technical Support

Who is online

Users browsing this forum: No registered users and 5 guests