Search found 218 matches

by darioit
24 Sep 2021 23:27
Forum: DOS Batch Forum
Topic: Compare two lists of elements, remove same and recycle for next run
Replies: 6
Views: 190

Re: Compare two lists of elements, remove same and recycle for next run

ok thank you now is better? @echo on setlocal EnableDelayedExpansion type nul >> "Recycle_%1" type nul >> "Recycle_%2" if exist "%1" type "%1" >> "Recycle_%1" sort.exe -u "Recycle_%1" > "%1" && del /q "Recycle_%1" if exist "%2" type "%2" >> "Recycle_%2" sort.exe -u "Recycle_%2" > "%2" && del /q "Rec...
by darioit
22 Sep 2021 22:41
Forum: DOS Batch Forum
Topic: Compare two lists of elements, remove same and recycle for next run
Replies: 6
Views: 190

Re: Compare two lists of elements, remove same and recycle for next run

Of course I really appreciate any bug fix or improvement, I chose to use this approach because the input file or the recycle file can be empty, and using other methods the comparison always failed, and also Recycle file must be always present at the end of program
by darioit
22 Sep 2021 12:23
Forum: DOS Batch Forum
Topic: Compare two lists of elements, remove same and recycle for next run
Replies: 6
Views: 190

Compare two lists of elements, remove same and recycle for next run

Hi everyone, this is a small contribution for the community to thank all the time I have been helped, I hope it will be useful to someone, and I hope don't made any mistakes lol Purpose: compare two list of elements to remove all duplicate in each list, also item remain will be used for next compare...
by darioit
28 Nov 2020 09:42
Forum: DOS Batch Forum
Topic: Find missing items in a list of element
Replies: 3
Views: 1953

Re: Find missing items in a list of element

many thanks! Works great as usual !
by darioit
28 Nov 2020 02:20
Forum: DOS Batch Forum
Topic: Find missing items in a list of element
Replies: 3
Views: 1953

Find missing items in a list of element

Hello, here I'm again to ask for your help about a problem that I wouldn't like to solve with many excel steps, but i'm too jackass to do by myself a correct script, I'm sure you be in my help :D The problem in very easy, find missing elements in a list of number, for example in this list below numb...
by darioit
16 Sep 2020 22:37
Forum: DOS Batch Forum
Topic: Forfiles and escape char
Replies: 2
Views: 1748

Re: Forfiles and escape char

Thank you Steffen, always the best!

I try only 1 caret before parentesis, but not before equal
by darioit
16 Sep 2020 04:16
Forum: DOS Batch Forum
Topic: Forfiles and escape char
Replies: 2
Views: 1748

Forfiles and escape char

Hello, this string works fine in dos shell curl --request POST "https://somesite/access_token" --user user:pass | grep -o -P -e "(?<=\"access_token\":\").+?(?=\")" but If I try this: for /f %%a in ('curl --request POST "https://somesite/access_token" --user user:pass ^| grep -o -P -e "(?<=\"access_t...
by darioit
04 Sep 2020 00:03
Forum: DOS Batch Forum
Topic: Merge two file in a new one
Replies: 4
Views: 2268

Re: Merge two file in a new one

I thought about it, if empty just copy

Thanks
Dario
by darioit
03 Sep 2020 04:00
Forum: DOS Batch Forum
Topic: Merge two file in a new one
Replies: 4
Views: 2268

Re: Merge two file in a new one

Many thank works fine, I had another problem, I use this command "findstr /livg:" for merge two file in a new one in both direction, but command FAIL if a second file is empty, how can I solve this problem? a.txt 1st_file_1st_row 2nd_file_2st_row 1st_file_3st_row 1st_file_4st_row 1st_file_4st_row 1s...
by darioit
21 Aug 2020 06:22
Forum: DOS Batch Forum
Topic: Merge two file in a new one
Replies: 4
Views: 2268

Merge two file in a new one

Hello, I try to solve in many way this problem without success, maybe you have the solution my goal is merge file a.txt and b.txt into new one, read first file and if first item is present in second file update it in c.txt file, if not just copy row from a.txt to c.txt first file a.txt AAA;2020-09-0...
by darioit
17 Apr 2019 04:47
Forum: DOS Batch Forum
Topic: Skip n. line before match pattern
Replies: 1
Views: 1677

Re: Skip n. line before match pattern

Solved put each row in a temp file and when match row print temp file
by darioit
16 Apr 2019 09:21
Forum: DOS Batch Forum
Topic: Skip n. line before match pattern
Replies: 1
Views: 1677

Skip n. line before match pattern

Hello folks, here another problem, I had to read text file and print it, but when I match a string starting tag AB3 for example year "2019" I want to skip raw (unknow) find and raw until prev tag AB3, after continue to read file with same method ex. AB1 data AB2 data AB3 2017 AB1 data AB3 2018 AB1 d...
by darioit
03 May 2018 02:23
Forum: DOS Batch Forum
Topic: get only last file of same type
Replies: 8
Views: 4560

Re: get only last file of same type

you're right, I miss it !!
Thank you
by darioit
02 May 2018 05:46
Forum: DOS Batch Forum
Topic: get only last file of same type
Replies: 8
Views: 4560

Re: get only last file of same type

Just a quick question, what's is this

Code: Select all

^>^>"%string%" 


it type file content on screen not in a file destination