Explain how GA file lock logic.
Post any question you may have in regards to GoAnywhere Director and let our talented support staff and other users assist you.
- AlBernardy Offline
- Posts: 2
- Joined: Wed Jul 18, 2012 7:30 am
Explain how GA file lock logic.
I would like to understand GA lock logic. I do a sql select to count number of records on a file, and if we do not have records i just exit. But when we have records, I try and do a ALCOBJ on the file, and GA gives me a error saying file is already locked. ??
- Support_Duane Offline
- Support Specialist
- Posts: 66
- Joined: Thu Mar 05, 2009 3:49 pm
Re: Explain how GA file lock logic.
The select statement to count the number of records creates a rowset that opens the file, so that an ALCOBJ cannot get an exclusive lock on the file. In order to release the file, you would use the Close Rowset task in the Miscellaneous folder. You will want to do a Set Variable 1.0 task to get the number of rows out of the rowset and place it into a variable before you close the rowset.