Search found 14 matches
- 22 Jun 2014 12:38
- Forum: DOS Batch Forum
- Topic: How to use for loop in the file name with space
- Replies: 3
- Views: 4275
How to use for loop in the file name with space
Hi I'm using the below code to get the count of the lines in csv file, It works fine if the folder name is without space, but if space available in the folder name then not getting the count. SET rootpath=%~dp0 set rootpath=%rootpath:~0,-4% set /a CustomerCodeUsageCounter=0 FOR /F "DELIMS=, TOK...
- 13 Jun 2014 10:51
- Forum: DOS Batch Forum
- Topic: Extract a portion of a command line output
- Replies: 7
- Views: 5377
Re: Alter the command line output text
Thanks all,
for /f "tokens=9 delims= " %%G in ('java -cp ../lib/EnhencedDataloader.jar com.salesforce.dataloader.security.EncryptionUtil -g "seeddata"') do echo %%G>%rootpath%bin\Key.txt
it works for me.

for /f "tokens=9 delims= " %%G in ('java -cp ../lib/EnhencedDataloader.jar com.salesforce.dataloader.security.EncryptionUtil -g "seeddata"') do echo %%G>%rootpath%bin\Key.txt
it works for me.

- 13 Jun 2014 08:19
- Forum: DOS Batch Forum
- Topic: Extract a portion of a command line output
- Replies: 7
- Views: 5377
Re: Alter the command line output text
hi Squashman ,
Thank u , have a single space in front , how to remove this?
Thank u , have a single space in front , how to remove this?
- 13 Jun 2014 05:00
- Forum: DOS Batch Forum
- Topic: Extract a portion of a command line output
- Replies: 7
- Views: 5377
Extract a portion of a command line output
Hi,, For encrypting password in a data loader i'm using the following code java -cp ../lib/EnhencedDataloader.jar com.salesforce.dataloader.security.EncryptionUtil -g "seeddata" > %rootpath%bin\Key.txt and writing the output in the key.txt file. as below, 2014-06-13 16:23:02,859 INFO [main...
- 23 May 2014 21:18
- Forum: DOS Batch Forum
- Topic: getting issue in calling many bat file in single bat file
- Replies: 2
- Views: 3423
getting issue in calling many bat file in single bat file
Hi, I'm calling 4 bat files in a single master bat file. Each bat file insert data in csv to object in salesforce.com. If i run the individual bat files it works for any number of data (tested upto 25k) If i run the master bat file, the first call is working fine, but in the second call getting the ...
- 18 May 2014 14:29
- Forum: DOS Batch Forum
- Topic: Error in sending mail using blat
- Replies: 1
- Views: 10548
Error in sending mail using blat
Hi Getting the following error, while sending mail using the Blat in batch script "The mail server doesn't like the sender name" This is my code to send mail blat %rootpath%EmailBody\ConnectionFailure.txt -server %server% -f %username% -u %username% -pw %password% -port %port% -to %to% -su...
- 18 May 2014 12:56
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
Re: if else not working
I mean error getting in CMD windows, even any thing like fatal error
for eg: "less was unexpected at this time"
If i want to write this error in my log means what need to do?
for eg: "less was unexpected at this time"
If i want to write this error in my log means what need to do?
- 18 May 2014 12:30
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
Re: if else not working
yes i had 'less' in my file..
Thank a lot, It's running now without error.
Is there any way to write the error we getting in cmd window in log file?
in case of the error my log file ends without any information.
Thank a lot, It's running now without error.
Is there any way to write the error we getting in cmd window in log file?
in case of the error my log file ends without any information.
- 18 May 2014 10:45
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
Re: if else not working
I changed the les to lss, and run in cmd
getting error as "less was unexpected at this time"
i tryied by changing the place of the code
getting error as "less was unexpected at this time"
i tryied by changing the place of the code
- 18 May 2014 09:09
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
Re: if else not working
If add the pause above the code in red i can see the line count if its below the window get closed. pause in green is working but the pause in darkred is not working.. @echo off setlocal EnableDelayedExpansion :::::::::::::: Lets set variables from XML file :::::::::::::: SET rootpath=%~dp0 set root...
- 18 May 2014 07:41
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
Re: if else not working
Not getting any error The statusfile is empty, im not getting any line in that set statusfile=%rootpath%InputCSV\ProcessStatus.csv if %UsageSuccessCounter% equ %Counter% ( echo Usage.csv,%Counter%,%SuccessCounter%,%date% %time%,True >> %statusfile% ) else ( set partUpload_flag=1 set PartialUploadMai...
- 18 May 2014 07:17
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
Re: if else not working
Hi This is my full bat file. i'm calling another bat files in the same folder to do the required operation and i will repeat the same for 3 more files in same script. i'm using blat to send mail. calling another bat, inserting records are working proper. getting the correct line counts too. But the ...
- 18 May 2014 05:30
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
Re: if else not working
Hi, I want to count the lines in input file, success file and error files. if the success count equal to the input count, then echo List.csv,%Counter%,%SuccessCounter%,%date% %time%,True >> %statusfile% else echo List.csv,%Counter%,%SuccessCounter%,%date% %time%,False>> %statusfile% If error count g...
- 18 May 2014 05:01
- Forum: DOS Batch Forum
- Topic: if else not working
- Replies: 16
- Views: 9912
if else not working
Hi , I want to count the lines in my input csv file , success and error files and based on the condition i need to write the status file if the success count equals to the input count then echo List.csv,%Counter%,%SuccessCounter%,%date% %time%,True >> in the statusfile else echo List.csv,%Counter%,%...