Changeset 8084 for branches/jhoblitt/ippdb/tests/pop.c
- Timestamp:
- Aug 2, 2006, 4:32:20 PM (20 years ago)
- File:
-
- 1 edited
-
branches/jhoblitt/ippdb/tests/pop.c (modified) (10 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/jhoblitt/ippdb/tests/pop.c
r8079 r8084 244 244 char exp_type[256]; 245 245 psS32 imfiles; 246 char class[256]; 247 248 dbh = psDBInit("localhost", "test", NULL, "test"); 249 if (!dbh) { 250 exit(EXIT_FAILURE); 251 } 252 253 if (!newExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&class)) { 246 247 dbh = psDBInit("localhost", "test", NULL, "test"); 248 if (!dbh) { 249 exit(EXIT_FAILURE); 250 } 251 252 if (!newExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles)) { 254 253 exit(EXIT_FAILURE); 255 254 } … … 287 286 char class[256]; 288 287 psF32 airmass; 289 psF 32ra;290 psF 32dec;288 psF64 ra; 289 psF64 dec; 291 290 psF32 exp_time; 292 293 dbh = psDBInit("localhost", "test", NULL, "test"); 294 if (!dbh) { 295 exit(EXIT_FAILURE); 296 } 297 298 if (!rawDetrendExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time)) { 291 psF64 background; 292 293 dbh = psDBInit("localhost", "test", NULL, "test"); 294 if (!dbh) { 295 exit(EXIT_FAILURE); 296 } 297 298 if (!rawDetrendExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time, &background)) { 299 299 exit(EXIT_FAILURE); 300 300 } … … 313 313 char class[256]; 314 314 psF32 airmass; 315 psF 32ra;316 psF 32dec;315 psF64 ra; 316 psF64 dec; 317 317 psF32 exp_time; 318 319 dbh = psDBInit("localhost", "test", NULL, "test"); 320 if (!dbh) { 321 exit(EXIT_FAILURE); 322 } 323 324 if (!rawScienceExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time)) { 318 psF64 background; 319 320 dbh = psDBInit("localhost", "test", NULL, "test"); 321 if (!dbh) { 322 exit(EXIT_FAILURE); 323 } 324 325 if (!rawScienceExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time, &background)) { 325 326 exit(EXIT_FAILURE); 326 327 } … … 335 336 char class_id[256]; 336 337 char uri[256]; 337 char stats[256]; 338 339 dbh = psDBInit("localhost", "test", NULL, "test"); 340 if (!dbh) { 341 exit(EXIT_FAILURE); 342 } 343 344 if (!rawImfilePop(dbh, (char **)&exp_id, (char **)&class, (char **)&class_id, (char **)&uri, (char **)&stats)) { 345 exit(EXIT_FAILURE); 346 } 347 348 psDBCleanup(dbh); 349 } 350 351 { 352 psDB *dbh; 353 char exp_id[256]; 354 char camera[256]; 355 char telescope[256]; 356 char exp_type[256]; 357 psS32 imfiles; 358 char filter[256]; 359 char class[256]; 338 339 dbh = psDBInit("localhost", "test", NULL, "test"); 340 if (!dbh) { 341 exit(EXIT_FAILURE); 342 } 343 344 if (!rawImfilePop(dbh, (char **)&exp_id, (char **)&class, (char **)&class_id, (char **)&uri)) { 345 exit(EXIT_FAILURE); 346 } 347 348 psDBCleanup(dbh); 349 } 350 351 { 352 psDB *dbh; 353 char exp_id[256]; 354 char camera[256]; 355 char telescope[256]; 356 char exp_type[256]; 357 psS32 imfiles; 358 char filter[256]; 359 psF32 airmass; 360 psF64 ra; 361 psF64 dec; 362 psF32 exp_time; 363 psF64 background; 364 char recipe[256]; 365 psS32 p1_version; 366 367 dbh = psDBInit("localhost", "test", NULL, "test"); 368 if (!dbh) { 369 exit(EXIT_FAILURE); 370 } 371 372 if (!p1PendingExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, &airmass, &ra, &dec, &exp_time, &background, (char **)&recipe, &p1_version)) { 373 exit(EXIT_FAILURE); 374 } 375 376 psDBCleanup(dbh); 377 } 378 379 { 380 psDB *dbh; 381 char exp_id[256]; 382 char camera[256]; 383 char telescope[256]; 384 char exp_type[256]; 385 psS32 imfiles; 386 char filter[256]; 360 387 psF32 airmass; 361 388 psF32 ra; 362 psF32 dec; 363 psF32 exp_time; 364 char recipe[256]; 365 psS32 p1_version; 366 367 dbh = psDBInit("localhost", "test", NULL, "test"); 368 if (!dbh) { 369 exit(EXIT_FAILURE); 370 } 371 372 if (!p1PendingExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time, (char **)&recipe, &p1_version)) { 373 exit(EXIT_FAILURE); 374 } 375 376 psDBCleanup(dbh); 377 } 378 379 { 380 psDB *dbh; 381 char exp_id[256]; 382 char camera[256]; 383 char telescope[256]; 384 char exp_type[256]; 385 psS32 imfiles; 386 char filter[256]; 387 char class[256]; 388 psF32 airmass; 389 psF32 ra; 390 psF32 dec; 391 psF32 exp_time; 389 psF64 dec; 390 psF64 exp_time; 391 psF64 background; 392 392 char recipe[256]; 393 393 psS32 p1_version; … … 399 399 } 400 400 401 if (!p2PendingExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time, (char **)&recipe, &p1_version, &p2_version)) {401 if (!p2PendingExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, &airmass, &ra, &dec, &exp_time, &background, (char **)&recipe, &p1_version, &p2_version)) { 402 402 exit(EXIT_FAILURE); 403 403 } … … 436 436 psS32 imfiles; 437 437 char filter[256]; 438 char class[256];439 438 psF32 airmass; 440 psF 32ra;441 psF 32dec;439 psF64 ra; 440 psF64 dec; 442 441 psF32 exp_time; 442 psF64 background; 443 443 char recipe[256]; 444 444 psS32 p1_version; … … 450 450 } 451 451 452 if (!p2DoneExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time, (char **)&recipe, &p1_version, &p2_version)) {452 if (!p2DoneExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, &airmass, &ra, &dec, &exp_time, &background, (char **)&recipe, &p1_version, &p2_version)) { 453 453 exit(EXIT_FAILURE); 454 454 } … … 486 486 psS32 imfiles; 487 487 char filter[256]; 488 char class[256];489 488 psF32 airmass; 490 psF 32ra;491 psF 32dec;489 psF64 ra; 490 psF64 dec; 492 491 psF32 exp_time; 492 psF64 background; 493 493 char recipe[256]; 494 494 psS32 p2_version; … … 500 500 } 501 501 502 if (!p3PendingExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time, (char **)&recipe, &p2_version, &p3_version)) {502 if (!p3PendingExpPop(dbh, (char **)&exp_id, (char **)&camera, (char **)&exp_type, &imfiles, (char **)&filter, &airmass, &ra, &dec, &exp_time, &background, (char **)&recipe, &p2_version, &p3_version)) { 503 503 exit(EXIT_FAILURE); 504 504 } … … 534 534 psS32 imfiles; 535 535 char filter[256]; 536 char class[256];537 536 psF32 airmass; 538 psF 32ra;539 psF 32dec;537 psF64 ra; 538 psF64 dec; 540 539 psF32 exp_time; 541 542 dbh = psDBInit("localhost", "test", NULL, "test"); 543 if (!dbh) { 544 exit(EXIT_FAILURE); 545 } 546 547 if (!detInputExpPop(dbh, &det_id, &iteration, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, (char **)&class, &airmass, &ra, &dec, &exp_time)) { 540 psF64 background; 541 542 dbh = psDBInit("localhost", "test", NULL, "test"); 543 if (!dbh) { 544 exit(EXIT_FAILURE); 545 } 546 547 if (!detInputExpPop(dbh, &det_id, &iteration, (char **)&exp_id, (char **)&camera, (char **)&telescope, (char **)&exp_type, &imfiles, (char **)&filter, &airmass, &ra, &dec, &exp_time, &background)) { 548 548 exit(EXIT_FAILURE); 549 549 }
Note:
See TracChangeset
for help on using the changeset viewer.
