Results 1 to 2 of 2
  1. #1
    Join Date
    Jan 2011
    Posts
    1

    Unanswered: WARNING: UNKNOWN DATATYPE 702 processed as string. Check pg_type.h to decode this OID

    As the title says I get this error:

    Code:
    WARNING: UNKNOWN DATATYPE 702 processed as string. Check pg_type.h to decode this OID
    Anyone knows what it is?

    More information:

    I can't find the file "pg_type.h"

    I am working on python code programmed by somebody else. The code is no longer functional, because the programm reads the abstime, but then gets a string returned, which it doesn't expect. So reading and writing works, but the datatype is incorrect. (Although my database is empty after running the data-import script, but is this because the program never completes, so never calls a closing command (like ';')?)

    I am running postgresql 8.4 on Linux fedora 12.
    This software was running correctly on Red Had EL5.
    The software might have been programmed on postgresql 8.1 or earlier.

    I see the following definition of OID 702 in /usr/share/pgsql/postgres.bki

    Code:
    insert OID = 702 ( abstime 11 10 4 t b D f t \054 0 0 1023 abstimein abstimeout abstimerecv abstimesend - - - i p f 0 -1 0 _null_ _null_ )
    Part of the logfile (merged console and python log) says this at the first occurance of the error:

    Code:
    2011-01-11 14:38:40,679 stats INFO CommandDB: insert into status (occur_date, id, ev_time, vehicle, xpos, ypos, ori, mission, control, moving, alarm, loaded, bat) values ('20100901', 4571, '20100901 23:59:58', 5, 127045, 32682, 270877, 0, 0, 0, 0, 0, 0) retval=OK
    2011-01-11 14:38:40,680 stats INFO CommandDB: insert into status (occur_date, id, ev_time, vehicle, xpos, ypos, ori, mission, control, moving, alarm, loaded, bat) values ('20100901', 4572, '20100901 23:59:58', 1, 207379, 33989, 180560, 1, 0, 0, 0, 0, 0) retval=OK
    2011-01-11 14:38:40,682 stats INFO CommandDB: insert into status (occur_date, id, ev_time, vehicle, xpos, ypos, ori, mission, control, moving, alarm, loaded, bat) values ('20100901', 4573, '20100901 23:59:58', 2, 227834, 32676, 270696, 0, 0, 0, 0, 0, 2) retval=OK
    2011-01-11 14:38:40,683 stats INFO CommandDB: insert into status (occur_date, id, ev_time, vehicle, xpos, ypos, ori, mission, control, moving, alarm, loaded, bat) values ('20100901', 4574, '20100901 23:59:59', 7, 159448, 33994, 683, 1, 0, 0, 0, 0, 0) retval=OK
    2011-01-11 14:38:40,685 stats INFO CommandDB: insert into status (occur_date, id, ev_time, vehicle, xpos, ypos, ori, mission, control, moving, alarm, loaded, bat) values ('20100901', 4575, '20100901 23:59:59', 6, 139081, 32685, 270259, 0, 0, 0, 0, 0, 0) retval=OK
    ok
    minimizing... 2011-01-11 14:38:40,689 stats INFO CommandDB: select id from error where occur_date='20100901' and alarm!=0 order by id retval=OK
    2011-01-11 14:38:40,691 stats INFO CommandDB: select vehicle, occur_time, alarm, withdraw_time, err_stat from error where occur_date='20100901' and id=1 retval=OK
    WARNING: UNKNOWN DATATYPE 702 processed as string. Check pg_type.h to decode this OID
    WARNING: UNKNOWN DATATYPE 702 processed as string. Check pg_type.h to decode this OID
    2011-01-11 14:38:40,699 stats INFO CommandDB: select min(times.ev_time) from ((select ev_time from status where id>(select id from status where occur_date='20100901' and ev_time>='2010-09-01 00:21:40+02' and vehicle=3 and alarm>=5 limit 1) and occur_date='20100901' and ev_time>='2010-09-01 00:21:40+02' and vehicle=3 and alarm<5 limit 1) union (select ev_time from status where occur_date='20100901' and ev_time>'2010-09-01 00:21:40+02' and vehicle=3 and alarm<5 limit 1)) as times retval=OK
    WARNING: UNKNOWN DATATYPE 702 processed as string. Check pg_type.h to decode this OID
    2011-01-11 14:38:40,700 stats INFO CommandDB: update error set withdraw_time='2010-09-01 00:21:45+02', err_stat=3 where occur_date='20100901' and id=1 retval=OK
    2011-01-11 14:38:40,701 stats INFO CommandDB: select vehicle, occur_time, alarm, withdraw_time, err_stat from error where occur_date='20100901' and id=2 retval=OK
    WARNING: UNKNOWN DATATYPE 702 processed as string. Check pg_type.h to decode this OID
    WARNING: UNKNOWN DATATYPE 702 processed as string. Check pg_type.h to decode this OID

  2. #2
    Join Date
    Aug 2009
    Location
    Olympia, WA
    Posts
    337
    Abstime is a deprecated type but it is still around. My guess about what is changed between the old version and new is the implicit casts. Honestly I've never used abstime. But I'm guessing it will work if you add the cast.

    Code:
    INSERT INTO status (occur_date) VALUES ('2010-09-01 00:21:45+02'::abstime)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •