Hello, I'm a student/intern and am something of a beginner at mainframes. I have a situation where I am supposed to update an existing flat file on an IBM mainframe through ftp while using a module in Visual Basic. However, that flat file does not seem to be updating. But if I write to a completely new flat file, the data goes through but with half the columns cut off.
Any assistance would be appreciated. If you need any more information, let me know
Help- FTP update of a flat file (TSO)
-
- Global moderator
- Posts: 3720
- Joined: Sat Dec 19, 2009 8:32 pm
- Skillset: Systems programming, SAS, COBOL, CICS, JCL, SMS, VSAM, etc.
- Referer: other forum
- Location: Dubuque, Iowa, USA
Re: Help- FTP update of a flat file (TSO)
You could have posted the FTP commands you are using, along with the characteristics of the mainframe data set. If you create a new mainframe data set, you need to fully specify the data set (LRECL, BLKSIZE, SPACE, DSORG, RECFM) in your FTP commands or your data set will not be created to your specifications. If putting data in an existing data set, are you getting any messages from the FTP session? Mainframe data sets can disallow updates, for example, depending on the security defined.
Re: Help- FTP update of a flat file (TSO)
Thanks for your response.
This is the operation performed by visual basic when calling FTP in my program:
Shell("ftp -n -v -i -s:""" & "\\File\Directory\Location\Folder\blah.txt "" our.mainframe.server.here.com", vbMinimizedNoFocus)
Here are the contents of blah.text:
user Username password
put
"\\File\Directory\Location\Folder\DATA.txt"
'My.Mainframe.Location.Flatfile'
bye
Unfortunately I can't give you any messages from the FTP session, as I don't rememeber them from yesterday (wish I had documented that) and am not sure I am allowed to try to make changes to the mainframe right now.
This is the operation performed by visual basic when calling FTP in my program:
Shell("ftp -n -v -i -s:""" & "\\File\Directory\Location\Folder\blah.txt "" our.mainframe.server.here.com", vbMinimizedNoFocus)
Here are the contents of blah.text:
user Username password
put
"\\File\Directory\Location\Folder\DATA.txt"
'My.Mainframe.Location.Flatfile'
bye
Unfortunately I can't give you any messages from the FTP session, as I don't rememeber them from yesterday (wish I had documented that) and am not sure I am allowed to try to make changes to the mainframe right now.
-
- Global moderator
- Posts: 2105
- Joined: Thu Jun 03, 2010 6:21 pm
- Skillset: Assembler, JCL, utilities
- Referer: zos.efglobe.com
Re: Help- FTP update of a flat file (TSO)
One obvious possible problem is you are not supplying the URL of the mainframe FTP server anywhere.
Re: Help- FTP update of a flat file (TSO)
steve-myers wrote:One obvious possible problem is you are not supplying the URL of the mainframe FTP server anywhere.
Sorry, I thought that was what "our.mainframe.server.here.com" was referring to.
-
- Global moderator
- Posts: 2105
- Joined: Thu Jun 03, 2010 6:21 pm
- Skillset: Assembler, JCL, utilities
- Referer: zos.efglobe.com
Re: Help- FTP update of a flat file (TSO)
Oh, sorry. I missed it.
I think your FTP text file is OK, but I do not have access to a mainframe FTP server and it's been a long time since I did. Does it work when you try it from a CMD window prompt?
Somehow there is something that does not look right in your shell( -- ) but I have no way to check it out myself.
I think your FTP text file is OK, but I do not have access to a mainframe FTP server and it's been a long time since I did. Does it work when you try it from a CMD window prompt?
Somehow there is something that does not look right in your shell( -- ) but I have no way to check it out myself.
Re: Help- FTP update of a flat file (TSO)
steve-myers wrote:Oh, sorry. I missed it.
I think your FTP text file is OK, but I do not have access to a mainframe FTP server and it's been a long time since I did. Does it work when you try it from a CMD window prompt?
Somehow there is something that does not look right in your shell( -- ) but I have no way to check it out myself.
I can't update 'My.Mainframe.Location.Flatfile' with the data from the new text file from command line either.
-
- Global moderator
- Posts: 3720
- Joined: Sat Dec 19, 2009 8:32 pm
- Skillset: Systems programming, SAS, COBOL, CICS, JCL, SMS, VSAM, etc.
- Referer: other forum
- Location: Dubuque, Iowa, USA
Re: Help- FTP update of a flat file (TSO)
Did you post exactly what you're doing? If so, have you researched whether or not your version of FTP even allows for line continuations the way you have split up the PUT subcommand? On the mainframe, a + can be used to indicate that a subcommand continues to the next line, but that is not necessarily true for Windows (or other platform) FTP clients. You may have to have the PUT <local file name> <remote file name> all on a single line.
Showing us the FTP output would VASTLY help in figuring out what is going on; especially when you use the -v option to get verbose output.
Showing us the FTP output would VASTLY help in figuring out what is going on; especially when you use the -v option to get verbose output.
-
- Similar Topics
- Replies
- Views
- Last post
-
- 3
- 6763
-
by sergeyken
View the latest post
Sun May 01, 2022 11:26 pm
-
-
PCOMM 64-bit Automation Macro failing to update WindowsTitle
by suriPCOMM » Tue Aug 31, 2021 5:33 am » in Simulators & Emulators - 0
- 7972
-
by suriPCOMM
View the latest post
Tue Aug 31, 2021 5:33 am
-
-
- 1
- 1778
-
by sergeyken
View the latest post
Fri Mar 26, 2021 11:59 pm
-
-
EZIOE004 Logical I/O error on file occurred reading VB file
by savitha_y » Mon Feb 15, 2021 7:54 pm » in CA-Easytrieve - 3
- 4958
-
by savitha_y
View the latest post
Wed Feb 17, 2021 5:02 am
-
-
-
File Handling 3 input files and 1 output file by using EZT
by pavan426 » Thu Sep 09, 2021 12:17 am » in CA-Easytrieve - 0
- 4421
-
by pavan426
View the latest post
Thu Sep 09, 2021 12:17 am
-