This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
we have *.dat data files which we need to read and parse as CSV files (there is one dat file for each day from last year) . I was able to read the file in CSV however the issue is to prepare the data ,i.e, in each file there are sub-sections meaning each data section is followed by the name of department to which the data belongs to along with the date. For example in the 1st snippet below row 3 consists of date stamp and name of department . We need to transform the data to look like shown in the second snippet where in the department # and date is added to the row starting with "SA" .
1st Snippet2nd Snippet
i was able to do the following wherein i just pulled in the rows which starts with SA and TI because the TI row consists of dept.# and date. Will really appreciate any help to achieve the task. Please find in attached the sample data .Thank you very much.