Open upsonp opened 3 months ago
Pretty self explanatory. The function is querying the BCDataTypes lookup for a row with both the passed in method and data_type sequence. If the method and sequence are mismatched count(*) returns zero and false is returned from the function. If more than zero rows are returned the function returns true and it's good to go.
The issue here though is DART comes with a copy of the BcDataTypes table which is loaded from a fixture file. The fixture file has to be manually updated using functions in the bio_tables.sync_tables package. If someone adds a new data type or updates a data type in the official Biochem database and the biochem fixtures file isn't updated there could be a mismatch for the data type code.
What would be nice is to include a button that, if the user can connect to a biochem database, would update the fixture file, or update a copy of the biochem lookup tables that are kept in a separate local database. Right now the biochem lookup tables are written to the mission database. Which is good in that the mission database is completely self contained, but it does create the potential issue of out-of-date lookup tables.
This issue is to dissect Biochem validation as part of issue #141
This issue is to dissect Biochem Data Type validation as part of issue #144
This is the validation code run by the biochem intake script on the Discrete Data Edits table (BCD). It can be found in the BioChem account on PTran under packages.