Department store retailer JCPenney Company is cautiously optimistic about future trading after reporting record second-quarter sales and profits.