Home > Archive > Cobol > May 2007 > Powercobol program running on Microsoft Terminal Server
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Powercobol program running on Microsoft Terminal Server
|
|
| Massimo 2007-05-25, 7:55 am |
| Hi, my program in powercobol uses a work file in c:\tmp\workfile.tmp
and it performs a sort of the data.
If I use a single program in a session of Microsoft Teminal Server/Win 2003
correctly work.
When use the program in more simultaneous sessions, I have the problem that
I use to the same works file in the same work areas and this creates me some
problems.
Can I have a suggestion on as use a file/work area separated for every open
session?.
The best regards.
Massimo from Rome Italy.
| |
| HeyBub 2007-05-25, 7:55 am |
| Massimo wrote:
> Hi, my program in powercobol uses a work file in c:\tmp\workfile.tmp
> and it performs a sort of the data.
> If I use a single program in a session of Microsoft Teminal
> Server/Win 2003 correctly work.
> When use the program in more simultaneous sessions, I have the
> problem that I use to the same works file in the same work areas and
> this creates me some problems.
> Can I have a suggestion on as use a file/work area separated for
> every open session?.
> The best regards.
> Massimo from Rome Italy.
Use a different file name?
| |
| Bob Iles 2007-05-25, 6:55 pm |
| Massimo wrote:
> Hi, my program in powercobol uses a work file in c:\tmp\workfile.tmp
> and it performs a sort of the data.
> If I use a single program in a session of Microsoft Teminal Server/Win 2003
> correctly work.
> When use the program in more simultaneous sessions, I have the problem that
> I use to the same works file in the same work areas and this creates me some
> problems.
> Can I have a suggestion on as use a file/work area separated for every open
> session?.
> The best regards.
> Massimo from Rome Italy.
>
>
>
Suggest using the tmp folder assign by windows term server.
Your should have this folder name available from the enSome cobols would
have this available bye using the environment variable "TEMP" or "TEMP".
Use the value of the temp as your folder and it will be unique to
each terminal services session.
bob.
| |
|
| In article <POA5i.18789$U01.216058@twister1.libero.it>,
Massimo <blue_max_53@hotmail.com> wrote:
>Hi, my program in powercobol uses a work file in c:\tmp\workfile.tmp
>and it performs a sort of the data.
>If I use a single program in a session of Microsoft Teminal Server/Win 2003
>correctly work.
>When use the program in more simultaneous sessions, I have the problem that
>I use to the same works file in the same work areas and this creates me some
>problems.
It sounds like the program was designed to be used by a single user on a
single machine and now you wish to modify it so that it can be used by
multiple and simultaneous users on a single machine.
Is this correct?
DD
| |
| Bob Iles 2007-05-25, 6:55 pm |
| docdwarf@panix.com wrote:
> In article <POA5i.18789$U01.216058@twister1.libero.it>,
> Massimo <blue_max_53@hotmail.com> wrote:
>
> It sounds like the program was designed to be used by a single user on a
> single machine and now you wish to modify it so that it can be used by
> multiple and simultaneous users on a single machine.
>
> Is this correct?
>
> DD
>
It could have been designed to be multi-user on a windows terminal where
each user "station" has a unique "c:" drive, but alas in terminal
services the c: drive is the same c: drive for everybody. The windows
variables will assign a unique temp from for each session. This is how
I have tackled similar problems in the past.
bob.
| |
|
| In article <34c5e$4656f58e$d06652e5$16392@FUSE.NET>,
Bob Iles <bobi@mikal.com> wrote:
>docdwarf@panix.com wrote:
>It could have been designed to be multi-user on a windows terminal where
>each user "station" has a unique "c:" drive, but alas in terminal
>services the c: drive is the same c: drive for everybody.
Exactly what I was driving at, Mr Iles... it 'could have been' a variety
of things, the solution might best be designed for what it is, hence my
query. It might be interesting to see how the Original Poster responds.
>The windows
>variables will assign a unique temp from for each session. This is how
>I have tackled similar problems in the past.
'Grandpa, tell us about the Steam Computer!'
'Eh? Huh? Whuh? Why, there was the time we had a bit of difficulty
allocating temp files, seems that someone got a look at the CEO's 'special
program' an' decided that this'd be a Right Fine Thing to deploy
company-wide... didn't realise, a'course, that this'd been written exactly
and precisely for the CEO an' doin' a 'all ya gotta do is...' clone...
don't know why they call it 'clone', a 'clone' started out as a botanical
term for somethin' grown from a twig... an' then became a term to identify
an individual genetically identical to its progenitors... 'cept fer them
pesky asexually reproducing species, them's clones, in a way... gotta
watch out fer that genetic drift, though... zzzzZZZZzzzzz....
.... eh? Huh? Whuh? Oh yeah, anyhow, someone grabbed a copy'a the CEO's
'special program' an' all kinds'a Really Bad Stuff began to happen on
account'a inappropriately-named temp files... so I reached in'ta the
bowels of the Execution Interface Block'n I grabbed on'ta th' terminal's
ID... this'uz before the days when ya'd have trouble doin' EXCIs from th'
CTG to th' CICS transaction server 2.3, a'course... anyhow, I grabbed
on'ta the EIBTRMID good 'n strong... had a right fine grip in those days,
don'cha know... could squeeze a glass'a juice outta a month-old lemon'd
been sittin' in the summer sun, I could... right fine grip... hands'a
steel, palms'a granite... pomegranates... say, I ever tell you about the
time me'n Persephone sneaked away from Demeter? Quite the trick, it was,
she was almost as good at keepin' watch as Argus, y'know...
zzzZZZzzzzz...'
DD
| |
| Pete Dashwood 2007-05-25, 6:55 pm |
|
"Massimo" <blue_max_53@hotmail.com> wrote in message
news:POA5i.18789$U01.216058@twister1.libero.it...
> Hi, my program in powercobol uses a work file in c:\tmp\workfile.tmp
> and it performs a sort of the data.
> If I use a single program in a session of Microsoft Teminal Server/Win
> 2003 correctly work.
> When use the program in more simultaneous sessions, I have the problem
> that I use to the same works file in the same work areas and this creates
> me some problems.
> Can I have a suggestion on as use a file/work area separated for every
> open session?.
> The best regards.
> Massimo from Rome Italy.
>
>
>
Hi Massimo,
I was interested to see Bob's suggestion regarding the Temp folder. (I
didn't know it worked like that).
If that works, fine, but if it doesn't...
If I were doing it I'd create the workfiles dynamically from within
PowerCOBOL and use a date/time stamp in the name of each one. As long as
they are all created with a .tmp suffix you should be able to clean them up
easily.
Let us know how you solve it.
Pete.
| |
|
| Massimo wrote:
> Hi, my program in powercobol uses a work file in c:\tmp\workfile.tmp
> and it performs a sort of the data.
> If I use a single program in a session of Microsoft Teminal Server/Win 2003
> correctly work.
> When use the program in more simultaneous sessions, I have the problem that
> I use to the same works file in the same work areas and this creates me some
> problems.
> Can I have a suggestion on as use a file/work area separated for every open
> session?.
You could use a temporary file in the system "temp", with the name being
the time to the millisecond. You could also use the user name, if the
user names are unique, and you're sure that the same user won't be
running multiple copies of the program.
Just a few ideas... :)
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~
~ / \ / ~ Live from Albuquerque, NM! ~
~ / \/ o ~ ~
~ / /\ - | ~ daniel@thebelowdomain ~
~ _____ / \ | ~ http://www.djs-consulting.com ~
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
~ GEEKCODE 3.12 GCS/IT d s-:+ a C++ L++ E--- W++ N++ o? K- w$ ~
~ !O M-- V PS+ PE++ Y? !PGP t+ 5? X+ R* tv b+ DI++ D+ G- e ~
~ h---- r+++ z++++ ~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~
"Who is more irrational? A man who believes in a God he doesn't see, or
a man who's offended by a God he doesn't believe in?" - Brad Stine
| |
| Massimo 2007-05-26, 3:55 am |
| Yes this is the problem.
Msassimo.
<docdwarf@panix.com> ha scritto nel messaggio
news:f36qbn$l7f$1@reader2.panix.com...
> In article <POA5i.18789$U01.216058@twister1.libero.it>,
> Massimo <blue_max_53@hotmail.com> wrote:
>
> It sounds like the program was designed to be used by a single user on a
> single machine and now you wish to modify it so that it can be used by
> multiple and simultaneous users on a single machine.
>
> Is this correct?
>
> DD
>
| |
|
| In article <uKR5i.19404$U01.222616@twister1.libero.it>,
Massimo <blue_max_53@hotmail.com> wrote:
>Yes this is the problem.
>Msassimo.
>
>
><docdwarf@panix.com> ha scritto nel messaggio
>news:f36qbn$l7f$1@reader2.panix.com...
[snip]
[color=darkred]
Right... it kind of 'smelled' that way. A few folks have already offered
solutions to be applied for this situation and which can be implemented by
a moderately experienced coder; anything else I might be able to provide
on this would probably have a Financial Cost associated with it... and you
know how Managers just love those, eh?
Bona fortuna!
DD
|
|
|
|
|