If you have filed a chapter 12 or more commonly a chapter 13 bankruptcy and received a discharge of one of those cases within the the last 6 years i.e. you cannot file a chapter 7 bankruptcy and receive a discharge.
This scenario is much less common in my experience than the debtor who has filed a chapter 7 bankruptcy previously and is seeking to file another chapter 7. In that situation the time between filing dates must be 8 years.
Read 11 U.S.C. Sect 727 (a)(9) for more.