Problems in olsqlforms30 and OCI (in C)

From: marc.colten <>
Date: Thu, 3 Sep 1992 16:35:21 GMT
Message-ID: <>

Well here I am again. I've been using olsqlform30 to create forms and the OCI (in "C" language) to insert and extract information. I've been hitting some problems and would appreciate some advice. Please e-mail and responses and I will summarize and post.

thanks in advance,

marc colten

  1. I created a table with a LONG field for comments. I can add and edit that field just fine (I have a ON-NEW-FIELD-INSTANCE trigger with EDIT_FIELD in it). However, my C program will not extract that field in any way.

    Some code is :

     struct {

char TROUBLE[65535]; } attr[3]; odefin(C0,5,attr[1].TROUBLE,(int) strlen(attr[1].TROUBLE),LONG, -1,dum,NULL,-1,-1,&dum2,&dum3);

   When I fetch the data, everything else comes up okay, but    I get a message that the field has been truncated. I    print it out character by character (assuming it was not    NULL terminated) and it's empty. I have tried putting the    field length directly into the odefin, and the field length    in the structure has been anywhere from 100 to 67000. I have    used LONG and STRCHR as identifiers. Nothing.

2) I have used structures with no array:

     struct {

} attr;

and it does not work. If I use attr[3], I can't get the data into attr[0]. But if I use a number > 1 and assign the output to attr[1].<field>, it always works. Can anyone explain this?

3) Can you do a query on a detail block and have the relevant

    information come up in the master block? It works fine     the other way. I do a query in a master block and it brings     up two records in the detail (which it should). I've tried     doing the reverse and it won't work. I set up a KEY-ENTQRY     trigger on the detail block with various commands:

         :<master>.field := <detail>.field;

    But no luck. execute_query wipes out the master block     before it does anything. What I wind up with is the     detail block shows the information what I wanted, while     the master block shows the data you'd get from a blank field.     

    What I want to do is:

        enter the query in the detail block.
        execute the query.
        The master block queries it's table to come up
          with the appropriate information based on the data
          placed in the detail.
        The master executes a query so the master and the detail
          (two records now) show the matching data.

    Is this possible?

4) Can you do a LOV on a block, or failing that on a non-enterable

    field? I just want a list relevant to the data I've queried     as an alternative to a second page, which is not really necessary     and really slows things down.

Thanks Received on Thu Sep 03 1992 - 18:35:21 CEST

Original text of this message