June 15, 2015 at 8:36 am
I have this silly question I suppose. I have an SQL table that captures this hierarchy. basically pallet can have a box, a box can have a folder, folder can have item.
The table has a unique id for the record, the type of container is captured by rectype uri (2 is item, 6 is folder, 4 is box and pallet is 8). Also the table has a field that captures the containers unique Id.
I need to write a query that displays the unique ID of records that are not in their proper container. need to find if item is under a box and not under a fulder or folder under pallet and not box
Basically show all uri and record ID where rcRecType URI is 2 and its rccontaineURI's rcRectype URI is
4 columns
1st column is URI with the following values : 467239,493565,493579,493586,493590,493604,493615,493647
2nd Column is RecordID with the following values : S-0619-0001-08-1
S-0691-0008-01-013 ,
S-0691-0008-01-027 ,
S-0691-0008-01-034 ,
S-0691-0008-01-038 ,
S-0691-0008-01-052 ,
S-0691-0008-01-063,
S-0691-0008-02-011 ,
3rd column is rcRecTypeUri with the following values :
2,4,6,8,5,2,2,4
4th Column is rcContainer URI with the following values 288543 ,300540,300540,300540,300540,300540,300540,300541
Viewing 0 posts
You must be logged in to reply to this topic. Login to reply