Hello. I have a txt file which contains "blocks" of data, separated by line containing #####. I need to extract information from each "block", and each time the #### appears that means the new epoch starts. For each block I check if it contains eg. "Station point:", "PPM", "MWF". Each Feature is then written in DB. Not all blocks give results for each Tester.
Here is an example of such file:
2020-03-23 08:01:13.8810 Info ###############################################################################################################################################
Â
2020-03-23 08:01:13.8810 Info Processing pointgroup 'MWS200_Fix' (Type:'Freie Stationierung') measured by 'MWS200'. GON/M]Â
2020-03-23 08:01:13.8810 Info Station point: 'MWS200'Â
2020-03-23 08:01:13.9122 Info Station coords: 2660392.8147,1251984.6680,416.3654Â
2020-03-23 08:01:13.9435 Info Reference coordinates of 'MWF204': E=2660397.8542,N=1251975.6158,H=416.0325Â
2020-03-23 08:01:13.9435 Info Calculated polar reference of 'MWF204': 147.8954,102.0449,10.3420Â
2020-03-23 08:01:13.9435 Info Measurement of 'MWF204' at 23.03.2020 08:00:20: Hz=147.8987, V=102.0421, Slope=10.3411, Temperature=11.1, Pressure=1013.3, AtmosPPM=0.0, SlopeAtmosPPMCorrected=10.3411, NullDist=10.3420, SlopeDistDiff=-0.0009, RefPPM=89.1845, VzCorr=0.0028, Azimuth=167.6609, Orientation=19.7621Â
2020-03-23 08:01:13.9747 Info Reference coordinates of 'MWF205': E=2660348.7659,N=1251956.1415,H=416.8883Â
2020-03-23 08:01:13.9903 Info Calculated polar reference of 'MWF205': 243.6485,99.3660,52.4608Â
2020-03-23 08:01:13.9903 Info Measurement of 'MWF205' at 23.03.2020 08:00:35: Hz=243.6504, V=99.3665, Slope=52.4610, Temperature=11.1, Pressure=1013.3, AtmosPPM=0.0, SlopeAtmosPPMCorrected=52.4610, NullDist=52.4608, SlopeDistDiff=0.0002, RefPPM=-4.2401, VzCorr=399.9995, Azimuth=263.4139, Orientation=19.7635Â
2020-03-23 08:01:14.0216 Info Reference coordinates of 'MWF206': E=2660342.7413,N=1251965.7471,H=416.4775Â
2020-03-23 08:01:14.0372 Info Calculated polar reference of 'MWF206': 257.2349,99.8669,53.5082Â
2020-03-23 08:01:14.0372 Info Measurement of 'MWF206' at 23.03.2020 08:00:48: Hz=257.2375, V=99.8669, Slope=53.5103, Temperature=11.1, Pressure=1013.3, AtmosPPM=0.0, SlopeAtmosPPMCorrected=53.5103, NullDist=53.5082, SlopeDistDiff=0.0021, RefPPM=-39.7455, VzCorr=0.0000, Azimuth=277.0003, Orientation=19.7628Â
2020-03-23 08:01:14.0685 Info Reference coordinates of 'MWF207': E=2660336.9264,N=1251975.0892,H=416.4712Â
2020-03-23 08:01:14.0685 Info Calculated polar reference of 'MWF207': 269.4285,99.8815,56.6827Â
2020-03-23 08:01:14.0841 Info Measurement of 'MWF207' at 23.03.2020 08:00:58: Hz=269.4313, V=99.8816, Slope=56.6835, Temperature=11.1, Pressure=1013.3, AtmosPPM=0.0, SlopeAtmosPPMCorrected=56.6835, NullDist=56.6827, SlopeDistDiff=0.0008, RefPPM=-14.6829, VzCorr=399.9998, Azimuth=289.1939, Orientation=19.7625Â
2020-03-23 08:01:14.1310 Info Reference coordinates of 'MWF209': E=2660388.8483,N=1252016.3496,H=416.5453Â
2020-03-23 08:01:14.1310 Info Calculated polar reference of 'MWF209': 372.3055,99.6415,31.9072Â
2020-03-23 08:01:14.1310 Info Measurement of 'MWF209' at 23.03.2020 08:01:14: Hz=372.3090, V=99.6413, Slope=31.9087, Temperature=11.1, Pressure=1013.3, AtmosPPM=0.0, SlopeAtmosPPMCorrected=31.9087, NullDist=31.9072, SlopeDistDiff=0.0015, RefPPM=-48.4750, VzCorr=0.0002, Azimuth=392.0710, Orientation=19.7620Â
2020-03-23 08:01:14.1466 Info Number of measured reference points: 5Â
2020-03-23 08:01:14.1466 Info Surveying Orientation: 19.762610, 0.000607 (valid)Â
2020-03-23 08:01:14.1466 Info VzCorrection: 0.000452, 0.001320 (valid)Â
2020-03-23 08:01:14.1622 Info PPM: -3.5918, 54.8919 (valid)Â
2020-03-23 08:01:14.1778 Info -------------------------------------------------------------------------------------------------------------------------------Â
2020-03-23 08:01:14.1778 Info Results of free station calculation (Reduced). Solution:ROBUST dGON/M]Â
2020-03-23 08:01:14.1778 Info Station Coordinates: 2660392.8148, 1251984.6679, 416.3655Â
2020-03-23 08:01:14.1935 Info Standard Deviations: 0.0003, 0.0004, 0.0002Â
2020-03-23 08:01:14.1935 Info Orientation: 19.76276, 0.000301Â
2020-03-23 08:01:14.1935 Info Scale: 1.00002113, 0.00000992Â
2020-03-23 08:01:14.2091 Info Hz, HzResid, HDist, ResidHDist, HeightDiff, ResidHDiff, E, N, HÂ
2020-03-23 08:01:14.2091 Info MWF204, 147.89873, 0.000749 (ok), 10.3595, -0.0010 (ok), -0.3324, 0.0006 (ok), 2660397.8542, 1251975.6158, 416.0325Â
2020-03-23 08:01:14.2091 Info MWF205, 243.65038, -0.000905 (ok), 52.4794, -0.0009 (ok), 0.5224, -0.0003 (ok), 2660348.7659, 1251956.1415, 416.8883Â
2020-03-23 08:01:14.2247 Info MWF206, 257.23750, -0.000225 (ok), 53.5311, 0.0010 (ok), 0.1121, 0.0001 (ok), 2660342.7413, 1251965.7471, 416.4775Â
2020-03-23 08:01:14.2247 Info MWF207, 269.43134, 0.000076 (ok), 56.7041, -0.0004 (ok), 0.1056, -0.0000 (ok), 2660336.9264, 1251975.0892, 416.4712Â
2020-03-23 08:01:14.2247 Info MWF209, 372.30895, 0.000804 (ok), 31.9305, 0.0008 (ok), 0.1800, 0.0002 (ok), 2660388.8483, 1252016.3496, 416.5453Â
2020-03-23 08:01:14.2560 Info Take the orientation from the free station module.Â
2020-03-23 08:01:14.2560 Info Free station valid.Â
2020-03-23 08:01:14.2716 Info -------------------------------------------------------------------------------------------------------------------------------Â
2020-03-23 08:01:27.9104 Info ###############################################################################################################################################Â
2020-03-23 08:01:27.9104 Info Processing pointgroup 'MWS200_Ori' (Type:'Orientierung') measured by 'MWS200'. nGON/M]Â
2020-03-23 08:01:27.9104 Info Station point: 'MWS200'Â
2020-03-23 08:01:27.9416 Info Station coords: 2660392.8148,1251984.6679,416.3655Â
2020-03-23 08:01:27.9729 Info Reference coordinates of 'MWF209': E=2660388.8483,N=1252016.3496,H=416.5453Â
2020-03-23 08:01:27.9729 Info Calculated polar reference of 'MWF209': 372.3082,99.6417,31.9072Â
2020-03-23 08:01:27.9729 Info Measurement of 'MWF209' at 23.03.2020 08:01:28: Hz=372.3092, V=99.6411, Slope=31.9082, Temperature=11.1, Pressure=1013.3, AtmosPPM=0.0, SlopeAtmosPPMCorrected=31.9082, NullDist=31.9072, SlopeDistDiff=0.0010, RefPPM=-30.8218, VzCorr=0.0006, Azimuth=392.0709, Orientation=19.7617Â
2020-03-23 08:01:27.9885 Info Number of measured reference points: 1Â
2020-03-23 08:01:27.9885 Info Surveying Orientation: 19.761675, 0.000000 (valid)Â
2020-03-23 08:01:27.9885 Info VzCorrection: 0.000594, 0.000000 (valid)Â
2020-03-23 08:01:28.0041 Info PPM: -30.8218, 0.0000 (valid)Â
2020-03-23 08:01:28.0041 Info Surveying orientation taken.Â
2020-03-23 09:00:56.9693 Info ###############################################################################################################################################Â
2020-03-23 09:00:56.9693 Info Processing pointgroup 'MWS200_Fix' (Type:'Freie Stationierung') measured by 'MWS200'. GON/M]Â
2020-03-23 09:00:56.9849 Info Station point: 'MWS200'Â
2020-03-23 09:00:57.0006 Info Station coords: 2660392.8148,1251984.6679,416.3655Â
2020-03-23 09:00:57.1256 Info Number of measured reference points: 0Â
2020-03-23 09:00:57.1256 Info Surveying Orientation: 0.000000, 0.000000 (not valid)Â
2020-03-23 09:00:57.1412 Info VzCorrection: 0.000000, 0.000000 (not valid)Â
2020-03-23 09:00:57.1412 Info PPM: 0.0000, 0.0000 (not valid)Â
2020-03-23 09:00:57.1568 Info -------------------------------------------------------------------------------------------------------------------------------Â
2020-03-23 09:00:57.1724 Info Results of free station calculation (Polar). Solution:ROBUST sGON/M]Â
2020-03-23 09:00:57.1724 Info Station Coordinates: 0.0000, 0.0000, 0.0000Â
2020-03-23 09:00:57.1724 Info Standard Deviations: 0.0000, 0.0000, 0.0000Â
2020-03-23 09:00:57.1881 Info Orientation: 0.00000, 0.000000Â
2020-03-23 09:00:57.1881 Info Scale: 1.00000000, 0.00000000Â
2020-03-23 09:00:57.1881 Info Free station not valid!Â
2020-03-23 09:00:57.2037 Info -------------------------------------------------------------------------------------------------------------------------------Â
Many thanks in advance for your assistance!