We are migrating some 7.3.4 databases to 8.1.5.
I thought that long datatypes were desupported in 8.1.5.

Our developers are having trouble with some
of their code that does uploads and downloads.
I really don't know much about Pro*C but see
several uses of long datatypes in their package.

Can someone tell me whether this Pro*C function call
will still work within 8.1.5?

int DATABASE_SYSMSG_Write (char type, long error_number, char *error_msg,
                           char *location, char *s1, char *s2, char *s3,
                           char *s4, char *s5, char *s6)
{
   int ret = 0;
        /* If the arguments include null pointers, set them to something
           so segmentation violation won't occur.
        */
        if (! s1) s1 = " ";
        if (! s2) s2 = " ";
        if (! s3) s3 = " ";
        if (! s4) s4 = " ";
        if (! s5) s5 = " ";
        if (! s6) s6 = " ";

 EXEC SQL BEGIN DECLARE SECTION;
      VARCHAR vtype[2];
      int     verror_number;
      VARCHAR verror_msg[81];
      char   *vlocation;
      int     vsql_error;
      VARCHAR vsql_msg[81];
      VARCHAR vs1[81];
      VARCHAR vs2[81];
      VARCHAR vs3[81];
      VARCHAR vs4[81];
      VARCHAR vs5[81];
      VARCHAR vs6[81];
   EXEC SQL END DECLARE SECTION;


   vtype.len = 1;
   vtype.arr[0] = type;
   verror_number = error_number;
   vsql_error = DATABASE_sql_num;
   vsql_msg.len = sprintf ((char *)vsql_msg.arr, "%s", DATABASE_sql_msg);
   vlocation = location;
   verror_msg.len = sprintf ((char *)verror_msg.arr, "%s", error_msg);
   vs1.len = sprintf ((char *)vs1.arr, "%s", s1);
   vs2.len = sprintf ((char *)vs2.arr, "%s", s2);
   vs3.len = sprintf ((char *)vs3.arr, "%s", s3);
   vs4.len = sprintf ((char *)vs4.arr, "%s", s4);
   vs5.len = sprintf ((char *)vs5.arr, "%s", s5);
   vs6.len = sprintf ((char *)vs6.arr, "%s", s6);

   EXEC SQL EXECUTE
      BEGIN
      Help_DeskPackage.AddBackendRecord (:vtype, :verror_number, :vsql_msg,
                                         :vsql_error, :vlocation, :verror_msg,
                                         :vs1, :vs2, :vs3, :vs4, :vs5, :vs6);
    END;
   END-EXEC;

   if (sqlca.sqlcode)
      {
      ret = -1;
      }

   return (ret);
}






Thanks,

Cherie Machler
Gelco Information Network




-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: 
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to