home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / database / ingres / 2338 < prev    next >
Encoding:
Text File  |  1993-01-21  |  3.0 KB  |  102 lines

  1. Newsgroups: comp.databases.ingres
  2. Path: sparky!uunet!spool.mu.edu!agate!ames!pacbell.com!rtech!odinba!karl
  3. From: karl@BofA.com (Karl Nicholas)
  4. Subject: Re: XVIEW and INGRES compatability problem! HELP!
  5. Message-ID: <1993Jan21.190711.2577@BofA.com>
  6. Organization: Bank of America, Capital Products, RMTG #5906
  7. References: <1993Jan20.040019.11802@BofA.com> <105904@netnews.upenn.edu>
  8. Date: Thu, 21 Jan 93 19:07:11 GMT
  9. Lines: 91
  10.  
  11. In article <105904@netnews.upenn.edu> jarnot@kin.lap.upenn.edu (Kevin J. Jarnot) writes:
  12. >In article <1993Jan20.040019.11802@BofA.com> karl@BofA.COM (Karl Nicholas) writes:
  13. >
  14. >    I came up with a quick fix in a sleepless haze over the weekend (don't
  15. >you love when problems like this pop up two weeks before a deadline? ;-)
  16. >Use the following function call:
  17. >
  18.  
  19.     Here is what I got from someone. Looks like pretty much the
  20. same thing. I repost it without permission, so I hope I am not
  21. stepping on any toes.
  22.  
  23.  
  24. From rtech!ingres.com!jbryson Wed Jan 20 10:20:07 1993
  25. Date: Wed, 20 Jan 93 10:16:02 PST
  26. From: jbryson@ingres.com (Jeff Bryson)
  27. To: karl@BofA.COM
  28. Subject: re:XVIEW and INGRES compatability problem
  29. Content-Length: 1531
  30. Status: RO
  31. X-Lines: 63
  32.  
  33. Karl,
  34.  
  35. Attached are two workarounds for your problem.
  36.  
  37. Ingres support will tell you that the workarounds are "UNSUPPORTED"....
  38. but both will work, I have told many people about these workarounds and
  39. no one has had any trouble.
  40.  
  41. The problem is really openwin and ESQL CONNECT.
  42. Ingres sets most(if not all) signals to QUIT!  I am not sure
  43. why this change happened, but, starting in 6.4 it did.
  44.  
  45. Ingres support does know about this and there are several
  46. BUGS/SIRS entered for this problem - #20493 and #44401
  47. are just two of them.
  48.  
  49. Good Luck,
  50.  
  51. Jeff Bryson
  52. ex-ESQL Support
  53.  
  54. ---------------------------------------------------------------------
  55. /********************************************/
  56. /* The easy Workaround                      */
  57. /* set signal to the default                */
  58. /********************************************/
  59. #include <stdio.h>
  60. #include <signal.h>
  61.  
  62. main()
  63. {
  64.   EXEC SQL CONNECT supp60;
  65.  
  66.   signal (SIGALRM, SIG_DFL);    /* just set signal to the default */
  67.  
  68.   /* ... do your code here... */
  69.  
  70.   EXEC SQL DISCONNECT;
  71. }
  72.  
  73.  
  74.  
  75. /********************************************/
  76. /* Workaround #2                            */
  77. /* Save the original signal                 */
  78. /********************************************/
  79. #include <stdio.h>
  80. #include <signal.h>
  81.  
  82. void    (*oldhand)();
  83.  
  84. main()
  85. {
  86.   oldhand = signal (SIGALRM, SIG_DFL);  /* save the original signal */
  87.  
  88.   EXEC SQL CONNECT supp60;
  89.  
  90.   signal (SIGALRM, oldhand);            /* restore the original signal */
  91.  
  92.   /* ... do your code here... */
  93.  
  94.   EXEC SQL DISCONNECT;
  95. }
  96.  
  97. -- 
  98.  +---------------------------------------------------------------------------+
  99.  | Karl Nicholas   (415) 953-0409    | Beer is good food.  Food is not beer. |
  100.  | karl@BofA.COM   uunet!odinba!karl | *** BofA is not me, I am not BofA *** |
  101.  +---------------------------------------------------------------------------+
  102.