CREATE TABLE table_50238 ("State" TEXT, "Type" TEXT, "Name" TEXT, "Title" TEXT, "Royal house" TEXT)

What state had a title of duke for the royal house of ji?
SELECT "State" FROM table_50238 WHERE "Title" = 'duke' AND "Royal house" = 'ji'
SELECT "State" FROM "table_50238" WHERE "Royal house" = 'ji' AND "Title" = 'duke'