Problem With Data Session

Problem With Data Session

Post by Ronald W. Robert » Mon, 24 Aug 1998 04:00:00



In my application I have data session set to the default and
AutoOpen and AutoClose are set to True in the data environment.
I only allow one form to be open at a time.  In my menu I go to a
routine
to check the form that is open and close it before I return and open the
new form.

Im having a problem with one form which has a grid with over a hundred
columns in the grid.  If  I open the grid form and then from the menu
open another
form that uses the same table, I get an error Cannot Access The
Selected Table.
It acts as if the form did not completely close and close all of the
tables before the
new form tries to open.  If I close the form with the close button in
the toolbar, it works ok.
I think this is because enough time has gone by between the click of the
close button and
the selection from the menu of the new form.

How can I be sure the old form is completely closed before I open the
new form?

TIA,

Ron

*********************
Ronald W. Roberts
Roberts Communication

                        ___
                       (   )
      \\\|///      ____|___|
     \\ - - //        /     \

---o00o-(_)-o00o--o00o---U---o00o----
           KEEP SMILING
     it makes people wonder
     what you've been up to

 
 
 

Problem With Data Session

Post by Tim Witor » Tue, 25 Aug 1998 04:00:00



> In my application I have data session set to the default and
> AutoOpen and AutoClose are set to True in the data environment.
> I only allow one form to be open at a time.  In my menu I go to a
> routine
> to check the form that is open and close it before I return and open the
> new form.

> Im having a problem with one form which has a grid with over a hundred
> columns in the grid.  If  I open the grid form and then from the menu
> open another
> form that uses the same table, I get an error Cannot Access The
> Selected Table.
> It acts as if the form did not completely close and close all of the
> tables before the
> new form tries to open.  If I close the form with the close button in
> the toolbar, it works ok.
> I think this is because enough time has gone by between the click of the
> close button and
> the selection from the menu of the new form.

> How can I be sure the old form is completely closed before I open the
> new form?

I would first determine what the difference in the session
behavior between the action that works and the one that doesn't.
When your menu itself closes the open form, how does it close
it?  Does it close it in the same way as it would be closed if
the user hit the close button in the toolbar,
i.e. Toolbar.cmdClose.Click() ?  I would make sure the same
thing is always used to close the form.  Then if you suspect a
timing issue, address that separately.

-- TRW

 
 
 

1. problem retrieving data from session based temporary table

Oracle 9i.

I have a procedure that returns a refcursor. Prior to this I do some
sorting using a temporary table. When I pick out chunks of code and
execute in SQL Plus, all works well (get data). But if I call the
procedure in SQL Plus, I don't get any rows. Using ADO in VB I get a
message saying object doesn't exist.

Here's the  block of code (I've missed out a lot eg exception
handling) :

pSQL :=
'select DISTINCT 1 As "Group_Order" ,
             "Title",
             "ID",
             "Business_Group",
             "Subject",
             "Publish_Date",
             "Employee_ID",
             "Preferred",
             "Surname",
             substr(a.Article,1,300) "Article"
    from     tblNews a
    left join tblLUSubject b on
             a.Subject_Code = b.Code
    inner join tblNewsDepartmentsLink d on
             a.ID = d.News_ID
    left join tblLUCorporateNewsApplic e on
             d.Business_Group_Code = e.Code
    left join tblLUDivision f on
             d.Division_Code = f.Code
    left join tblStaffDirectory c on
             a.Employee_ID = c.Employee_ID';

execute immediate 'insert into tbltmpNewsSearch ' || psql;

update tbltmpNewsSearch
set "Group_Order" = 2
where "Subject" <> '' or "Subject" is not null;

open pCursor for --this works (no need to use fetch with refcursors)
select  "Title",
        "ID",
        "Business_Group",
        "Subject",
        "Publish_Date",
        "Employee_ID",
        "Preferred",
         "Surname",
         "Article"
    from   tbltmpNewsSearch
    Order By "Group_Order", "Publish_Date" DESC, "Title";

commit;  --empties table

<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
What am I doing wrong?

Thanks,
Paul

2. Major sql mail problem

3. Problems setting private data session.

4. Problem with using DAO to wite to a specific record.

5. Bizarre : Initialization problem with private data session??

6. Summary of new configuration file and data directory locations

7. Java programs running on a Windows NT session via a server session

8. OCP Exam 1 Preparation

9. dynamically created session and database : cannot avoid login prompt - fine with default session

10. Forcing an ALTER SESSION at session startup - How?

11. v$session, aborted sessions

12. Help: Can we alter session for other sessions

13. Current Session ID (SID) v$session