I am given a HUGE table with two columns, `date6`, `date8` that contain dates stored as integers. Unfortunately, one is 6 digits, and one is 8 digits, i.e. `date6` could be `201002` for February 2010, and `date8` could be `20100205` for 5th February 2010. 

I am trying to do `WHERE` operations, for example keeping only observations when the two dates match, or keeping only observations if `date6` is the previous month of `date8`. Being somewhat new to SQL, I am trying to piece together what I need and any advice is greatly appreciated. 

Working with Orcacle 12.1.0