mirror of
https://forgemia.inra.fr/theophile.terraz/acoused.git
synced 2026-10-30 03:10:40 +01:00
SQL: read: Minor change.
This commit is contained in:
1 parent
8ef6c22f7c
commit
66024342dc
1 file changed
+14
-1
@@ -551,7 +551,11 @@ class ReadTableForOpen:
|
|||||||
FROM SedimentsFile
|
FROM SedimentsFile
|
||||||
'''
|
'''
|
||||||
|
|
||||||
data = self.execute(query)[0]
|
res = self.execute(query)
|
||||||
|
if len(res) == 0:
|
||||||
|
return
|
||||||
|
|
||||||
|
data = res[0]
|
||||||
|
|
||||||
stg.path_fine = data[0]
|
stg.path_fine = data[0]
|
||||||
stg.filename_fine = data[1]
|
stg.filename_fine = data[1]
|
||||||
@@ -594,6 +598,9 @@ class ReadTableForOpen:
|
|||||||
stg.frac_vol_sand = []
|
stg.frac_vol_sand = []
|
||||||
stg.frac_vol_sand_cumul = []
|
stg.frac_vol_sand_cumul = []
|
||||||
|
|
||||||
|
if len(data) == 0:
|
||||||
|
return
|
||||||
|
|
||||||
for d in data:
|
for d in data:
|
||||||
stg.sample_fine.append((d[0], d[1]))
|
stg.sample_fine.append((d[0], d[1]))
|
||||||
stg.distance_from_bank_fine.append(d[2])
|
stg.distance_from_bank_fine.append(d[2])
|
||||||
@@ -642,6 +649,9 @@ class ReadTableForOpen:
|
|||||||
'''
|
'''
|
||||||
|
|
||||||
data = self.execute(query)
|
data = self.execute(query)
|
||||||
|
if len(data) == 0:
|
||||||
|
return
|
||||||
|
|
||||||
it = iter(data[0])
|
it = iter(data[0])
|
||||||
|
|
||||||
stg.calib_acoustic_data = next(it)
|
stg.calib_acoustic_data = next(it)
|
||||||
@@ -708,6 +718,9 @@ class ReadTableForOpen:
|
|||||||
'''
|
'''
|
||||||
|
|
||||||
data = self.execute(query)
|
data = self.execute(query)
|
||||||
|
if len(data) == 0:
|
||||||
|
return
|
||||||
|
|
||||||
it = iter(data[0])
|
it = iter(data[0])
|
||||||
|
|
||||||
stg.path_calibration_file = next(it)
|
stg.path_calibration_file = next(it)
|
||||||
|
|||||||
Reference in new issue
Block a user