Hello,
I would like to learn how to debug an error. anyone can point me to the right direction?
I have 2 installations of openacs. one 5.1 and one HEAD.
I think I have the same error in them. Below is the error message I get in the HEAD installation.
I would like to LEARN TO FIND a sollution to this error MYSELF.
what should I do?
I tried to grep:
"where last_queried < current_timestamp - 1" within categories package and found it in the postgres procs.
maybe the problem is the syntax used?
=====================================
06/Jul/2004:00:16:01
    Error: Ns_PgExec: result status: 7 message: ERROR:  Unable to identify an operator '-' for types 'timestamptz' and 'integer'
    You will have to retype this query using an explicit cast
06/Jul/2004:00:16:01
    Error: Database operation "dml" failed
ERROR:  Unable to identify an operator '-' for types 'timestamptz' and 'integer'
    You will have to retype this query using an explicit cast
SQL:
        delete from category_search
        where last_queried < current_timestamp - 1
Database operation "dml" failed
ERROR:  Unable to identify an operator '-' for types 'timestamptz' and 'integer'
    You will have to retype this query using an explicit cast
SQL:
        delete from category_search
        where last_queried < current_timestamp - 1
    while executing
"ns_pg_bind dml nsdb0 {
        delete from category_search
        where last_queried < current_timestamp - 1
      }"
    ("uplevel" body line 1)
    invoked from within
"uplevel $ulevel [list ns_pg_bind $type $db $sql"
    ("postgresql" arm line 2)
    invoked from within
"switch $driverkey {
                oracle {
                    return [uplevel $ulevel [list ns_ora $type $db $sql] $args]
                }
       ..."
    invoked from within
"db_exec dml $db $full_statement_name $sql"
    ("uplevel" body line 2)
    invoked from within
"uplevel 1 $code_block "
    invoked from within
"db_with_handle -dbn $dbn db {
            db_exec dml $db $full_statement_name $sql
        }"
    (procedure "db_dml" line 100)
    invoked from within
"db_dml delete_old_searches """
    (procedure "category_synonym::search_sweeper" line 2)
    invoked from within
"category_synonym::search_sweeper"
    ("eval" body line 1)
    invoked from within
"eval [concat [list $proc] $args]"
    (procedure "ad_run_scheduled_proc" line 42)
    invoked from within
"ad_run_scheduled_proc {t f {0 16} category_synonym::search_sweeper {} 1089038332 0 f}"
================================================