1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
|
ij> AUTOCOMMIT OFF;
ij> -- MODULE DML004
-- SQL Test Suite, V6.0, Interactive SQL, dml004.sql
-- 59-byte ID
-- TEd Version #
-- AUTHORIZATION HU
set schema HU;
0 rows inserted/updated/deleted
ij> --O SELECT USER FROM HU.ECCO;
VALUES USER;
1
--------------------------------------------------------------------------------------------------------------------------------
HU
ij> -- RERUN if USER value does not match preceding AUTHORIZATION comment
-- date_time print
-- TEST:0008 SQLCODE 100:SELECT on empty table !
SELECT EMPNUM,HOURS
FROM WORKS
WHERE PNUM = 'P8'
ORDER BY EMPNUM DESC;
EM&|HOURS
----------
ij> -- PASS:0008 If 0 rows selected, SQLCODE = 100, end of data?
-- END TEST >>> 0008 <<< END TEST
-- ****************************************************************
-- TEST:0009 SELECT NULL value!
-- setup
INSERT INTO WORKS
VALUES('E9','P9',NULL);
1 row inserted/updated/deleted
ij> -- PASS:0009 If 1 row is inserted?
SELECT EMPNUM
FROM WORKS
WHERE HOURS IS NULL;
EM&
---
E9
ij> -- PASS:0009 If EMPNUM = 'E9'?
SELECT EMPNUM, HOURS
FROM WORKS
WHERE PNUM = 'P9'
ORDER BY EMPNUM DESC;
EM&|HOURS
----------
E9 |NULL
ij> -- PASS:0009 If EMPNUM = 'E9' and HOURS is NULL?
-- restore
ROLLBACK WORK;
ij> -- END TEST >>> 0009 <<< END TEST
-- ******************************************************************
-- NO_TEST:0161 FETCH NULL value without indicator, SQLCODE < 0!
-- Testing Indicators
-- **********************************************************
-- NO_TEST:0162 FETCH NULL value with indicator syntax!
-- Testing indicators
-- ****************************************************************
-- NO_TEST:0010 FETCH truncated CHAR column with indicator!
-- Testing indicators
-- *************************************************////END-OF-MODULE
;
ij>
|