Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only. Moving forward, myibi is our community platform to learn, share, and collaborate. We have the same Focal Point forum categories in myibi, so you can continue to have all new conversations there. If you need access to myibi, contact us at myibi@ibi.com and provide your corporate email address, company, and name.


Connect to myibi

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Datamigrator
 Login/Join
 
Gold member
posted
!findstr /R /N "^" d:\AwiFileOutput.csv | find /C ":"

This command is return the number of rows in a csv file.

need to capture it in a &&RowCnt variable to use in flow

This message has been edited. Last edited by: <Kathryn Henning>,


IWay SM 5.6, 6.01, 6.1, 6.9, 7.0
EDI, XML, XSD, WF 8.0, DM 77,8.0 asp.net, SQL Server
 
Posts: 87 | Registered: February 27, 2009Report This Post
Guru
posted Hide Post
Is it possible to change the tile to somethign more relevant to your question than "Datamigrator?"

The problem is that the DOS command find doesn't return the number of rows; it returns a 0 or 1 whether it was found or not. It outputs the number of rows to the console. So you just need to re-direct the output and read in the value.

!findstr /R /N "^" &FNAME | find /C ":" >lines.txt
FILEDEF LINES DISK lines.txt 
-RUN
-READ LINES &COUNT.A2
-TYPE Count &COUNT


N/A
 
Posts: 397 | Location: New York City | Registered: May 03, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders