N.Y. CPL. LAW § 210.20 : NY Code - Section 210.20: Motion to dismiss or reduce indictment

1.  After arraignment upon an indictment, the superior court may, upon
  motion  of  the  defendant, dismiss such indictment or any count thereof
  upon the ground that:
    (a)  Such indictment or count is  defective,  within  the  meaning  of
  section 210.25; or
    (b)   The evidence before the grand jury was not legally sufficient to
  establish the offense charged or any lesser included offense; or
    (c)  The grand jury proceeding was defective, within  the  meaning  of
  section 210.35; or
    (d)    The defendant has immunity with respect to the offense charged,
  pursuant to section 50.20 or 190.40; or
    (e)  The prosecution is barred by reason of  a  previous  prosecution,
  pursuant to section 40.20; or
    (f)  The prosecution is untimely, pursuant to section 30.10; or
    (g)  The defendant has been denied the right to a speedy trial; or
    (h)    There  exists  some other jurisdictional or legal impediment to
  conviction of the defendant for the offense charged; or
    (i)  Dismissal is required in the interest  of  justice,  pursuant  to
  section 210.40.
    1-a. After arraignment upon an indictment, if the superior court, upon
  motion  of  the defendant pursuant to this subdivision or paragraph b of
  subdivision one of this section challenging the legal sufficiency of the
  evidence before the grand jury, finds that the evidence before the grand
  jury was not legally sufficient  to  establish  the  commission  by  the
  defendant  of  the  offense  charged  in  any count contained within the
  indictment, but was legally sufficient to establish the commission of  a
  lesser  included  offense,  it  shall  order  the count or counts of the
  indictment with respect to which the finding is made reduced  to  allege
  the  most  serious  lesser  included  offense  with respect to which the
  evidence before the grand jury was sufficient,  except  that  where  the
  most  serious lesser included offense thus found is a petty offense, and
  the court does not find evidence of the commission of any crime  in  any
  other  count  of the indictment, it shall order the indictment dismissed
  and a prosecutor's information charging the petty offense filed  in  the
  appropriate  local  criminal  court. The motion to dismiss or reduce any
  count of an indictment based on legal  insufficiency  to  establish  the
  offense charged shall be made in accordance with the procedure set forth
  in  subdivisions  one through seven of section 210.45, provided however,
  the court shall state on the record the  basis  for  its  determination.
  Upon  entering  an  order  pursuant to this subdivision, the court shall
  consider the appropriateness of any securing order  issued  pursuant  to
  article 510 of this chapter.
    2.    A  motion  pursuant to this section, except a motion pursuant to
  paragraph (g) of subdivision one,  should  be  made  within  the  period
  provided  in section 255.20.  A motion made pursuant to paragraph (g) of
  subdivision one must be made prior to the commencement of trial or entry
  of a plea of guilty.
    3.  Upon the motion, a defendant who is in a  position  adequately  to
  raise  more  than  one ground in support thereof should raise every such
  ground upon which he intends to challenge the indictment.  A  subsequent
  motion based upon any such ground not so raised may be summarily denied,
  although the court, in the interest of justice and for good cause shown,
  may  in  its  discretion  entertain  and dispose of such a motion on the
  merits notwithstanding.
    4.  Upon dismissing an indictment or a count thereof upon any  of  the
  grounds  specified  in  paragraphs  (a), (b), (c) and (i) of subdivision
  one, or, upon dismissing a superior court information or a count thereof

  upon  any  of  the  grounds  specified  in  paragraphs  (a)  or  (i)  of
  subdivision  one,  the court may, upon application of the people, in its
  discretion authorize the people to submit the charge or charges  to  the
  same or another grand jury.  When the dismissal is based upon some other
  ground,  such  authorization  may  not  be  granted.   In the absence of
  authorization to submit or resubmit, the order of dismissal  constitutes
  a  bar  to  any  further  prosecution  of  such  charge  or  charges, by
  indictment or otherwise, in any criminal court within the county.
    5. If the court dismisses one or more counts of an indictment, against
  a defendant who was under  the  age  of  sixteen  at  the  time  of  the
  commission of the crime and who did not lack criminal responsibility for
  such  crime  by  reason  of infancy, and one or more other counts of the
  indictment  having  been  joined  in  the  indictment  solely  with  the
  dismissed  count  pursuant  to  subdivision six of section 200.20 is not
  dismissed, the court must direct that  such  count  be  removed  to  the
  family  court  in  accordance  with article seven hundred twenty-five of
  this chapter.
    6. The effectiveness of an order reducing a  count  or  counts  of  an
  indictment  or  dismissing  an  indictment and directing the filing of a
  prosecutor's  information  or  dismissing  a  count  or  counts  of   an
  indictment  charging  murder  in  the  first  degree shall be stayed for
  thirty days following the entry  of  such  order  unless  such  stay  is
  otherwise  waived  by  the  people.  On or before the conclusion of such
  thirty-day period, the  people  shall  exercise  one  of  the  following
  options:
    (a)  Accept  the  court's  order  by  filing  a reduced indictment, by
  dismissing the indictment and filing a prosecutor's information,  or  by
  filing  an  indictment  containing  any  count or counts remaining after
  dismissal of the count or counts charging murder in the first degree, as
  appropriate;
    (b) Resubmit the subject count or counts to the same  or  a  different
  grand  jury  within  thirty  days  of  the  entry  of  the order or such
  additional time as the court may permit upon a showing  of  good  cause;
  provided,  however,  that if in such case an order is again entered with
  respect to such count or counts pursuant to subdivision  one-a  of  this
  section,  such  count  or  counts  may not again be submitted to a grand
  jury. Where the people exercise this option, the  effectiveness  of  the
  order  further shall be stayed pending a determination by the grand jury
  and the filing of a new indictment, if voted, charging  the  resubmitted
  count or counts;
    (c)  Appeal  the order pursuant to subdivision one or one-a of section
  450.20. Where the people exercise this option, the effectiveness of  the
  order  further  shall  be  stayed  in  accordance with the provisions of
  subdivision two of section 460.40.
    If the people fail to exercise  one  of  the  foregoing  options,  the
  court's  order  shall  take  effect  and  the  people  shall comply with
  paragraph (a) of this subdivision.