Skip to content

Commit bcded93

Browse files
committed
IRSA-5367 add more sourceid patten patten matching
1 parent 5287b83 commit bcded93

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/firefly/java/edu/caltech/ipac/astro/ibe/datasource/WiseIbeDataSource.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,10 @@ else if (sourceProductLevel == "3a") {
268268
queryParam.setWhere(ref1B);
269269
} else if (sourceProductLevel == "3a") {
270270
String coaddId = refSourceId.trim().substring(0,13);
271-
DataProduct sourcedt = DataProduct.ALLSKY_4BAND_3A;
271+
String sourceSchema = getSchemaFromSourceId(refSourceId);
272+
String ss = sourceSchema.replaceAll("-", "_").toUpperCase();
273+
String tt = sourceProductLevel.toUpperCase();
274+
DataProduct sourcedt = DataProduct.valueOf(ss + "_" + tt);
272275
String sourceTable = sourcedt.getSourceTable();
273276
String sourceSpec = WISE + "." + sourceTable + "(\"source_id\":\"" + refSourceId + "\")";
274277
String ref3A = "coadd_id="+"\'"+coaddId+"\'"; //get the images with the coadd_id given by the source_id
@@ -621,7 +624,7 @@ public enum DataProduct {
621624
PRELIM_1B("prelim","p1bm_frm", "prelim_p1bs_psd", "links-prelim/l1b/"),
622625
PRELIM_3A("prelim","p3am_cdd", "prelim_p3as_psd", "links-prelim/l3a/"),
623626
PRELIM_POSTCRYO_1B("prelim_postcryo","p1bm_frm", "prelim_2band_p1bs_psd", "links-postcryo-prelim/l1b-2band/"),
624-
ALLWISE_MULTIBAND_3A("allwise","p3am_cdd", "allsky_4band_p1bs_psd", "links-allwise/l3a/"), // TODO: change for production, changed XW
627+
ALLWISE_MULTIBAND_3A("allwise","p3am_cdd", "allwise_p3as_psd", "links-allwise/l3a/"), // TODO: change for production, changed XW
625628
ALLSKY_4BAND_1B("allsky", "4band_p1bm_frm", "allsky_4band_p1bs_psd", "links-allsky/l1b-4band/"),
626629
ALLSKY_4BAND_3A("allsky", "4band_p3am_cdd", "allsky_4band_p3as_psd", "links-allsky/l3a-4band/"),
627630
CRYO_3BAND_1B("cryo_3band", "3band_p1bm_frm", "allsky_3band_p1bs_psd", "links-3band/l1b-3band/"),

0 commit comments

Comments
 (0)