
191 Ill. App.3d 1041 (1989)
548 N.E.2d 524
LLOYD WYRICK, Plaintiff-Appellant,
v.
TIME CHEMICAL, INC., et al., Defendants-Appellees.
No. 1-88-0665.
Illinois Appellate Court  First District (2nd Division).
Opinion filed December 5, 1989.
Rehearing denied January 9, 1990.
*1042 Andrew J. Horwitz, Marc A. Perper, and John M. Kovac, all of Horwitz, Horwitz & Associates, Ltd., of Chicago, for appellant.
Patrick J. Reynolds and Gregory G. Lawton, both of Modesto, Reynolds & McDermott, of Chicago, for appellee Time Chemical, Inc.
John M. Barnes, of Law Offices of John M. Barnes, of Chicago, for appellee Murphy Carpet Supplies, Inc.
Barry G. Collins, of Tuttle, Vedral & Collins, of Des Plaines, and Arthur S. Bresnahan and Douglas A. Miller, both of Bresnahan & Garvey, and Richard C. Robin and Edward A. Cohen, both of Vedder, Price, Kaufman & Kammholz, both of Chicago, for other appellees.
Reversed and remanded.
PRESIDING JUSTICE BILANDIC delivered the opinion of the court:
Plaintiff, Lloyd Wyrick, brought this action for personal injuries against defendant, Time Chemical, Inc. (hereinafter defendant Time), and others. On August 20, 1987, pursuant to the motion of defendant Time, plaintiff's cause of action was dismissed "for his failure to appear for a discovery deposition." Plaintiff's motions to vacate and reconsider the dismissal were denied. Plaintiff appeals.
Defendant Time's motion to dismiss plaintiff's cause of action alleged that plaintiff's deposition was "continued on eleven occasions" and that plaintiff "failed to appear" at a scheduled deposition on April 30, 1987. The motion was not supported by any affidavits.
On August 20, 1987, plaintiff's counsel appeared before Judge Nicholson to oppose defendant Time's motion. He asked the clerk to hold the motion while he attended to another hearing in a different courtroom. Counsel for defendant Time appeared shortly thereafter. The motion was passed and recalled later, prior to the time that counsel for plaintiff returned. Essentially, counsel for Time advised the court of the contents of his motion that "[t]he deposition has been set eleven times" and the deposition was set for April 30, 1987, and plaintiff "didn't show up."
"THE COURT: I'll grant your motion, counsel.
MR. REYNOLDS: Thank you.
THE COURT: Maybe now we will hear from them.
MR. REYNOLDS: Thank you."
*1043 The court then entered the order dismissing plaintiff's cause of action "for his failure to appear at a discovery deposition."
Shortly thereafter, counsel for plaintiff returned and discovered that his case against defendant Time was dismissed. The court asked the clerk whether in fact a hold had been placed on the motion. The clerk replied, "[Y]es, we did. On the third time other counsel stepped up * * and wanted to proceed." Judge Nicholson understood the problems of busy lawyers, crowded calendars, and the operations of specialized contested motion and pretrial calendars. The court said:
"I don't know why they came here with it. Usually if it's a question, if the question arises someone will come up with an order which says it still says all contested motions would go to the motions Court. In my thinking it's not a contested motion, but why don't you  you could do either one of two things, you could file your motion to vacate or you could simply call the opposing counsel and offer your client within the time between now and the 31st.
I'm a firm believer that lawyers ought to talk to each other. You could save yourself and your opponent and this Court some time. If you have an order for the, where the time is extended to August 31st, offer to present him prior to that time. That should solve the whole thing.
MR. KOVAC: Yes, it should, your Honor, but at present there is an existing order which has dismissed plaintiff's cause of action.
THE COURT: Based on that, all right. You offer to present your client, if he agrees come in with an agreed order to vacate this order.
MR. KOVAC: Okay, your Honor.
THE COURT: Is there any reason  [?]
MR. KOVAC: I'm not sure that we are going to be able  .
THE COURT: The two of you are reasonable people."
Following the hearing, plaintiff's counsel called counsel for defendant Time to schedule the deposition prior to the August 31, 1987, date set in the pretrial order for taking the depositions of "all parties." Counsel for defendant Time and all other counsel for defendants, except counsel for defendant Murphy Carpet, agreed. This refusal precluded the rescheduling of the deposition. Plaintiff then proceeded with his timely motion to vacate the dismissal order.
Counsel for defendant Murphy Carpet refused to agree to the deposition of plaintiff on the assumption that plaintiff's cause of action was dismissed as to all of the defendants, including his client.


*1044 I
 1 The record reveals that only defendant Time moved to dismiss plaintiff's cause of action. The August 20, 1987, dismissal order granted the motion of defendant Time. The other defendants did not make similarly motions, did not joining in defendant Time's motion, and were not present when defendant Time's motion was presented and the dismissal order entered. "An order must be interpreted within the context of the motion or motions which accompany it." Comet Casualty Co. v. Schneider (1981), 98 Ill. App.3d 786, 793, 424 N.E.2d 911.
We therefore, conclude that plaintiff's cause of action was dismissed only as to defendant Time.

II
 2 Supreme Court Rule 219(c) provides in pertinent part:
"If a party * * * unreasonably refuses to comply with [the provisions of Rules 201 through 218,] or fails to comply with any order entered under these rules, the court, on motion, may enter, in addition to remedies elsewhere specifically provided, such orders as are just, including, among others, the following:
* * *
(v) * * * that this [suit] be dismissed with or without prejudice; * * *." (107 Ill.2d R. 219(c).)
Imposition of sanctions under Rule 219 is a matter within the discretion of the trial court; the reviewing court will uphold the decision absent an abuse of discretion. Amoco Oil Co. v. Segall (1983), 118 Ill. App.3d 1002, 1013, 455 N.E.2d 876.
 3, 4 Dismissal is a drastic sanction which should not be invoked unless a party's actions demonstrate deliberate, wilful or contumacious disregard of the court's authority. (White v. Henrotin Hospital Corp. (1979), 78 Ill. App.3d 1025, 398 N.E.2d 24; Williams v. City of Chicago (1977), 54 Ill. App.3d 974, 370 N.E.2d 119, appeal denied (1978), 71 Ill.2d 601; Hansen v. Skul (1977), 54 Ill. App.3d 1, 369 N.E.2d 267; In re Estate of Fado (1976), 43 Ill. App.3d 759, 357 N.E.2d 195; Department of Transpiration v. Zabel (1975), 29 Ill. App.3d 407, 330 N.E.2d 878; Schwartz v. Moats (1972), 3 Ill. App.3d 596, 277 N.E.2d 529.) While a court may impose sanctions necessary to accomplish the object of discovery, it may not impose sanctions intended primarily as punishment. (Gallo v. Henke (1982), 107 Ill. App.3d 21, 27, 436 N.E.2d 1068; Williams, 54 Ill. App.3d at 978.) No sanction should be imposed unless the noncompliance is unreasonable, and any order entered as a result thereof must be just. (White, 78 Ill. *1045 App. 3d at 1028.) A "just" order within the meaning of Rule 219 is one which, to the degree possible, ensures both discovery and a trial on the merits. White, 78 Ill. App.3d at 1028.
 5 Because dismissal is such a radical sanction, it should be employed only as a last resort, when all other enforcement powers at the court's disposal fail to advance the litigation. (White, 78 Ill. App.3d at 1028; United Excavating & Wrecking, Inc. v. J.L. Wroan & Sons, Inc. (1976), 43 Ill. App.3d 101, 356 N.E.2d 1160.) Where noncompliance with a discovery order is not "contumacious," it is an abuse of discretion to dismiss the complaint and to refuse to vacate the dismissal. White, 78 Ill. App.3d at 1030.
 6 In the case at bar, defendant Time's motion to dismiss mistakenly alleged that plaintiff's deposition had "been continued eleven times." However, 10 of the 11 continuances were by agreement of the parties. The court also was not informed of the fact that plaintiff had noticed the depositions of defendants and that those depositions were also continued from time to time by agreement.
On August 20, 1987, defendant Time and the other defendants had not been deposed, even though the pretrial deadline for "depositions of all parties" was August 31, 1987 (11 days later). The court also was not informed that plaintiff complied with all written discovery.
Plaintiff made an effort to be deposed prior to the August 31, 1987, deadline set in the pretrial order. This effort failed because of the erroneous assumption of defendant Murphy Carpet that plaintiff's action against it was dismissed.
The trial court's dismissal order is based on the erroneous allegations in defendant Time's motion and inaccurate representations, unsupported by affidavit or testimony, that plaintiff "did not show" for a deposition on "at least eleven occasions." The court's misapprehension in this regard is confirmed by the court's own stated findings to the effect that "there were eleven times or 22 times" that plaintiff "did not show" for his deposition; that the defendants "came in and [obtained] many orders"; that plaintiff "did not obey those orders"; and that "someone is disobeying orders with reckless abandonment."
While it is true that a date was set for plaintiff's deposition, which plaintiff did not attend, there is nothing in the record, nor did defendants ever claim, that his absence on that one occasion was deliberate, wilful or contumacious.
Since the trial court based its dismissal on the erroneous assumption that plaintiff missed "eleven or 22 depositions," the dismissal should be vacated. As a matter of law, defendants have failed to demonstrate *1046 deliberate, wilful and contumacious disregard of the court's authority sufficient to justify a dismissal. See White, 78 Ill. App.3d 1025, 398 N.E.2d 24; Williams, 54 Ill. App.3d 974, 370 N.E.2d 119.
Accordingly, the judgment of the circuit court of Cook County dismissing plaintiff's cause of action against defendant Time is reversed and this case is remanded for further proceedings consistent with the views expressed herein.
Reversed and remanded.
HARTMAN and SCARIANO, JJ., concur.
