Question: I have a df like the following:

```
   DATE_MIN DATE_MAX
214 1994-06-29  2010-07-12
125 1969-10-26  2011-10-10
123 2013-07-02  2015-01-29
74  2006-01-05  2016-06-20

```

Columns are: DATE\_MIN, DATE\_MAX

I would like to plot a long vertical chart with as many horizontal
 lines as df rows. 

* With date range in x axis
* With index in y axis,
hence each line is horizontal, they don't cross each other.

So I want to show which rows have some time overlapping because the lines would have overlapping area (not crossing).

Super thanks in advance!

Answer: 
Add the characters to the first field or remove them from the second

```
select * 
from register 
left outer join plan on register.RegisterID+'_0' = plan.RegisterID

```

```
select * 
from register 
left outer join plan on register.RegisterID = REPLACE(plan.RegisterID,'_0','')

```

If the length of the ID is always the same there is a third option

```
select * 
from register 
left outer join plan on register.RegisterID = LEFT(plan.RegisterID,6)

```
You could try something like:

```
 SELECT *
  FROM Register R
 LEFT OUTER JOIN [Plan] P
  ON LEFT(R.RegisterID, LEN(R.RegisterID) - 2) = P.RegisterID

```

The expression `LEFT(R.RegisterID, LEN(R.RegisterID) - 2)` will remove the '\_0' from Register.RegisterID and the JOIN will work.