Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fields to iseq_product_metrics for BGE libraries #224

Merged
merged 2 commits into from
Dec 13, 2023
Merged

Conversation

ces
Copy link
Contributor

@ces ces commented Nov 28, 2023

No description provided.

@mgcam mgcam self-requested a review December 11, 2023 09:05
Copy link
Member

@mgcam mgcam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested schema update and generation of ORM, both are OK. Would be good to exclude deprecated features from the float field definition.

-- Add columns for metrics useful for BGE project.

ALTER TABLE `iseq_product_metrics` \
ADD COLUMN `mean_bait_target_coverage` FLOAT(8,2) UNSIGNED DEFAULT NULL \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As of MySQL 8.0.17, UNSIGNED for floats and FLOAT(M,D) expression are deprecated and will be removed https://dev.mysql.com/doc/refman/8.0/en/numeric-type-syntax.html

Copy link
Member

@mgcam mgcam Dec 11, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mysql> ALTER TABLE `iseq_product_metrics` \
    ->   ADD COLUMN `mean_bait_target_coverage` FLOAT(8,2) UNSIGNED DEFAULT NULL \
    ->     COMMENT 'Mean coverage of the design target regions of a bait library (if used and known)' \
    ->     AFTER `on_or_near_bait_percent`, \
    ->   ADD COLUMN `target_autosome_filter` varchar(30) DEFAULT NULL \
    ->     COMMENT 'Filter used to produce the autosome target stats file' \
    ->     AFTER `target_percent_gt_coverage_threshold`, \
    ->   ADD COLUMN `target_autosome_length` bigint unsigned DEFAULT NULL \
    ->     COMMENT 'The total length of the autosomes only target regions' \
    ->     AFTER `target_autosome_filter`, \
    ->   ADD COLUMN `target_autosome_mapped_bases` bigint unsigned DEFAULT NULL \
    ->     COMMENT 'The number of mapped bases passing the autosome target filters' \
    ->     AFTER `target_autosome_length`;
Query OK, 0 rows affected, 2 warnings (4 min 29.17 sec)
Records: 0  Duplicates: 0  Warnings: 2

mysql> show warnings;
+---------+------+--------------------------------------------------------------------------------------------------------------------------+
| Level   | Code | Message                                                                                                                  |
+---------+------+--------------------------------------------------------------------------------------------------------------------------+
| Warning | 1681 | Specifying number of digits for floating point data types is deprecated and will be removed in a future release.         |
| Warning | 1681 | UNSIGNED for decimal and floating point data types is deprecated and support for it will be removed in a future release. |
+---------+------+--------------------------------------------------------------------------------------------------------------------------+
2 rows in set (0.00 sec)

@mgcam mgcam merged commit 5eb877e into wtsi-npg:devel Dec 13, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants