• Introducing Dark Mode! Switch by clicking on the lightbulb icon next to Search or by clicking on Default style at the bottom left of the page!

Citrix Error when using B4700230

Ken

Active Member
Hi All,
I've created a program that writes a file to a networked directory using B0500025 ( Export to flat file), I then copy that file to another directory and then delete the original using B4700230(Delete or Copy Flat File.)
All is well, Life is good, everything is working... until I run it on Citrix.
The first business function works (creating the file in the networked directory,) the problem is the B4700230 fails when copying the file. However, it does correctly delete the original file during the second call to it.

Here is what my debug log has during the call to B4700230:
Jun 23 14:20:13 ** 555/476 On MERP1, calling Business function
DeleteOrCopyFlatFile for KEN. (BSFNLevel = 1)
Jun 23 14:20:13 ** 555/476 Entering JDB_InitUser with commit mode 0
Jun 23 14:20:13 ** 555/476 Entering JDB_BeginTransaction
Jun 23 14:20:13 ** 555/476 Entering JDB_FreeUser
Jun 23 14:20:13 ** 555/476 Entering JDB_InitUser with commit mode 0
Jun 23 14:20:13 ** 555/476 Entering JDB_BeginTransaction
Jun 23 14:20:13 ** 555/476 Entering GetUserProfileCache
Jun 23 14:20:13 ** 555/476 GetUserProfileCache returns the value from ghEnv
Jun 23 14:20:13 ** 555/476 Entering JDB_FreeUser
Jun 23 14:20:13 ** 555/476 Return value is 2 for
DeleteOrCopyFlatFile. (BSFNLevel = 1)

Jun 23 14:20:13 ** 555/476 RT: BSFN: Returned 2:
DeleteOrCopyFlatFile App: P58003 Form: W58003A [T:ldc F:D:\b7\system\jdeuser\JDECGRT\RT_BSFN.cpp Ln:1481 Lv:BUSINESS FUNCTION]

Jun 23 14:20:13 ** 555/476 RT: BSFN DID NOT RETURN SUCCESS


After this line it goes on to note that the next call to the Business function (The delete) completed successfully.

Any ideas?
TIA




Ken
OneWorldXe B7333 SP13
Windows NT, AS400
 

Carl_Fisher

Well Known Member
How are you defining the Network Drive to the business function? Do you use
a Drive letter? If you do does this drive letter exist on the Citrix Server
or is it reassigned from the local Client? I think your problem may well be
that the Citrix server cannot see the Folder where the copy is targeted, due
to Drive letters being reassigned - look for a $Drive letter.



OW733.3 Xe SP 14.2
Enterprise Server - Intel NT + Oracle 8.0.6
Client - Citrix TSE + Some 95 and NT PC's
 

David Robertson

Reputable Poster
Hi,
are you using a share common to all of your citrix boxes?
I have used the same BSFN's a lot (in both APPL's and UBE's running on citrix). The path you specify must be visible, and accessable, under NT on the citrix server. As standard, B4700230 (on B7332) does not return an error if it fails, so this can be a bit of a problem.

BSFN B0500025 (ExportToFlatFile) to write records to a file
BSFN B4700230 (DeleteOrCopyFlatFile), where the action parameter:
cActionOnFlatFiles
1 = Delete Flat File
2 = Copy (Append) Flat File to New Location
3 = Delete Both Flat File and New File

Check in debug to make sure you have constructed your path correctly (although I think you said it worked under a fat client, so it's a citrix specific problem?).
Turn up your debugging level to hopefully see more info from the call in JDEDEBUG.log.
I think the only problem can be one of the paths you are passing to B4700230 is invalid to the citrix server.

David
 

Ken

Active Member
Thanks for the ideas, I thought I'd pass on some more info since I'm not sure what may apply.

Our Enterprise server is the AS/400.

The way I have my code is passing the servername and shared drive( ie:
\\mph008\D$\filename.txt) There are no mappings on the citrix server.
This morning,I did recreate the program and and instead used a Mapped drive path F:\filename.txt. I then created a mapped drive on the citrix server, it failed at the same point.

Everyone has permission to the directories I'm writing to, so permissions shouldn't be a problem.

And yes, this only happens on Citrix, the pgm works on a fat client.

I appreciate all of your input!

Ken
OneWorldXe B7333 SP13
Windows NT, AS400
 

David Robertson

Reputable Poster
I have tried both ways, where I specify a network path
"\\mph008\D$\filename.txt" and by setting up a share as "F:" which is mapped to something like "\\mph008\D$\". Provide you can actually see the path from the citrix session, and the authorities are correct, then I have no problems with this (so far) running on B7332. My UBE's, applications, and table converters all run on the citrix server fine.

The enterprise server should make no difference, unless you are launching this as a batch job there. That won't work. If the share is there... not sure. On Unix boxes you path has to have "/" not "\" etc., if you're running a UBE on the unix logic server.

Try turning up your debug level, and see what turns up in there.
 

Carl_Fisher

Well Known Member
Where is the BSFN really running? Do you have the W environments enabled? If
you do then this BSFN is actually running on the enterprise Server! This may
cause a few problems if the Share is not available from there.

Try mapping this BSFN to run Local in the OCM.




OW733.3 Xe SP 14.2
Enterprise Server - Intel NT + Oracle 8.0.6
Client - Citrix TSE + Some 95 and NT PC's
 

Ken

Active Member
Hi David,
Ah the plot thickens. I rewrote the pgm so that I could see what was happening at each step and low and behold, the reason the B4700230(DeleteOrCopyFlatFile) was failing was because it couldn't find the file that was supposedly written by B0500025 (ExportToFlatFile). Because I was not receiving an error on B0500025, I thought the problem lay with B4700230. However the prb is really with B0500025, even though it doesn't return an error it is NOT writing to the directory. Again, this all works fine on a fat client, it only fails in Citrix. I was able to ping the networked drive from the Citrix machine as well as map a drive.
I then rewrote the pgm so it would write the file to the Citrix server, again it failed in the Citrix environment( but of course without an error message.)
I've asked our Citrix guy to relook at his settings, but he says everything is fine.

I also changed my debugging to show more info, but didn't get anything else.

Any more thoughts?
Thanks,
Ken


Ken
OneWorldXe B7333 SP13
Windows NT, AS400
 

DBohner-(db)

Legendary Poster
Ken,

Thoughts - :
Does the Citrix client have authority to write to the shared drive?
Does the Citrix client have the drive mapped correctly?
Have you reviewed the NT Event Logs for Security or Applications events?
Are you hard coding the through the BSFN to write to a mapped or URL'd
folder?

Just a few thoughts... you asked...



Daniel Bohner
drbohner@existinglight.net
www.existinglight.net
JDE - XE & AS/400
JDE - B7331 & MS SQL 7x
 

David Robertson

Reputable Poster
Hi Ken,

Hmmm... I've really only had this problem when OW couldn't see the path name I had specified, and yes, it does appear to all work correctly, just disppearing off into byteland somewhere.
Things to try...
- check the OCM to see where B0500025 is running. Make sure it is running local. The mapping may be different between the fat client and citrix. Is it the same user for both tests?
- quadruple check your path is valid from the citrix point of view.
- is this an APPL? Or a UBE? If it's a UBE, are you sure it's running local?
- Can you paste in the code from the event rule for calling these BSFN's to this site? JDEDebug.log as well for the appropriate section would be good.
- If you are using a variable for the path name, check the value just before and after the call to the BSFN using debug.
- ???

Dave
 

Ken

Active Member
Hi List,
After a nice long weekend took the info that all of you had supplied and attacked the problem again. Talked to the person we have that did the mappings and THAT was the problem. It was mapped differently on the Citrix server. Once we remapped it to run locally everything worked fine.
I'd like to thank everyone for their help, being new to this system I'm finding this list a very valuable resource.

Ken
OneWorldXe B7333 SP13
Windows NT, AS400
 

Neal Scarr

Active Member
Hi

Was there any resolution to the problem with B0500025 because I'm having the same issue ?

I can create a text file to a UNC network path from a fat client (Windows 2000) using B0500025 within a custom application, but when I run the same application from a citrix box (Windows 2000 Advanced Server) the text file is created in the B7 folder on the citrix box and not the network path.

Any ideas ?

Cheers

Neal
 
Top