Question: I have the below SQL statement:

```
SELECT 
    B.ID
    CASE 
       WHEN (B.NAME <> E.NAME OR (B.NAME IS NULL AND E.NAME IS NOT NULL))
          THEN 'NAME DOES NOT MATCH' 
    END AS NAME_ERROR, 
    B.NAME AS B_NAME, 
    E.NAME AS E_NAME
FROM 
    EMPLOYEE E, BACKUP B
WHERE 
    E.ID = B.ID

```

I am using the above SQL but what I want is that the `NAME_ERROR` column along with `B_NAME` and `E_NAME` should not get select altogether if they match. 

Currently, if they match, `B_NAME` & `E_NAME` get selected, along with `NAME_ERROR` column which is populated with null which I don't want.

Thanks

Answer: 
This seems to work for me:

```
@Root(strict = false)
@Path("Name")
@Text(required = false)
public class Name {

```
SimpleXml can do it:

```
public class Name {
    @XmlName("Name")
    private String name;
}

final SimpleXml simple = new SimpleXml();
final Name n = simple.fromXml(xml, Name.class);
System.out.println(n.name);

```

Will print:

```
Fred

```

SimpleXml is in maven central:

```
<dependency>
    <groupId>com.github.codemonstur</groupId>
    <artifactId>simplexml</artifactId>
    <version>1.5.4</version>
</dependency>

```