In an action for a judgment declaring that the plaintiff is not obligated to defend or indemnify A & B Roofing, Inc., in an underlying action entitled Harris v 1345 Hewlett Owners, Inc., commenced in the Supreme Court, Suffolk County, under index No. 03-27653, the plaintiff appeals from so much of an order of the Supreme Court, Suffolk County (Jones, Jr., J.), entered December 15, 2009, as denied its motion for summary judgment declaring that it is not obligated to indemnify A & B Roofing, Inc., in the underlying action.
Ordered that the order is reversed insofar as appealed from, on the law, with costs, the plaintiffs motion for summary judgment declaring that it is not obligated to indemnify A & B Roofing, Inc., in the underlying action is granted, and the matter is remitted to the Supreme Court, Suffolk County, for the entry of a judgment declaring that the plaintiff is not so obligated.
In an underlying personal injury action, Timothy Harris alleged in his complaint that he was injured while working as an employee of A & B Roofing, Inc. (hereinafter A & B), “in or about July 2002.” A & B had secured a policy of insurance from the plaintiff, which was in effect from March 7, 2002, through March 7, 2003. The plaintiff provided an initial defense to A & B in the underlying action, but disclaimed coverage based on various provisions of the policy.
At Harris’s deposition, he testified that the accident occurred between Halloween 2001 and November 4, 2001. Thereafter, Harris amended the complaint in the underlying action to allege that the accident occurred in or about October or November 2001.
*763The plaintiff then commenced this action against A & B, among others, for a judgment declaring that it is not obligated to defend or indemnify A & B in the underlying action. The plaintiff moved for summary judgment on the complaint, arguing that it had no duty to defend or indemnify A & B in the underlying action because the accident occurred before the effective date of its policy with A & B. The Supreme Court, inter alia, granted that branch of the motion which was for summary judgment declaring that the plaintiff is not obligated to defend A & B in the underlying action, but denied that branch of the motion which was for summary judgment declaring that the plaintiff is not obligated to indemnify A & B in the underlying action. The plaintiff filed a subsequent motion for summary judgment declaring that it is not obligated to indemnify A & B in the underlying action. In support of the subsequent motion, the plaintiff submitted, among other things, a third amended bill of particulars in the underlying action, which alleged, in essence, that the accident occurred between October 31, 2001, and November 4, 2001. The Supreme Court denied the motion.
“Although multiple summary judgment motions in the same action should be discouraged in the absence of a showing of newly discovered evidence or other sufficient cause, a subsequent summary judgment motion may be properly entertained when it is substantively valid and when the granting of the motion will further the ends of justice while eliminating an unnecessary burden on the resources of the courts” (Valley Natl. Bank v INI Holding, LLC, 95 AD3d 1108, 1108 [2012]; see Town of Angelica v Smith, 89 AD3d 1547, 1549 [2011]; Rose v Horton Med. Ctr., 29 AD3d 977 [2006]). Here, the plaintiffs subsequent motion for summary judgment was substantively valid, and the granting of it would have furthered the ends of justice.
An insurance company’s duty to indemnify “flows from a contractual relationship” (Erdman v Eagle Ins. Co., 239 AD2d 847, 849 [1997]; see Riviello v Waldron, 47 NY2d 297, 306 [1979]; 1-3 New Appleman New York Insurance Law § 3.04 [1]). Here, since the subject accident occurred prior to the effective date of A & B’s policy with the plaintiff, there was no contractual relationship between the plaintiff and A & B at the time of the accident and, thus, the plaintiff has no duty to indemnify A & B in the underlying action (cf. International Furniture Rentals of NY/CT v United States Fid. & Guar. Co., 256 AD2d 308 [1998]). Indeed, if the correct date of the accident had been properly pleaded in the complaint in the underlying action, the plaintiff would have had no duty to defend or indemnify A & B from the inception of the action. Under these circumstances, where the *764plaintiff established, prima facie, that it had no duty to indemnify A & B, and A & B failed to raise a triable issue of fact in opposition, the Supreme Court should have granted the plaintiffs motion for summary judgment declaring that the plaintiff is not obligated to indemnify A & B in the underlying action (see Marazzo v Frontier Ins. Co., 189 AD2d 755, 756 [1993]).
Since this is a declaratory judgment action, the matter must be remitted to the Supreme Court, Suffolk County, for the entry of a judgment declaring that the plaintiff is not obligated to indemnify A & B Roofing, Inc., in the underlying action (see Lanza v Wagner, 11 NY2d 317, 334 [1962], appeal dismissed 371 US 74 [1962], cert denied 371 US 901 [1962]). Rivera, J.P., Dickerson, Leventhal and Hall, JJ., concur.