April 25, 1997


Sandata, Inc.
26 Harbor Park Drive
Port Washington, New York  11050

     Re: Sandata, Inc./Amendment No. 2 to Registration Statement on Form S-3

Gentlemen:

     In our capacity as counsel to Sandata,  Inc., a Delaware  corporation  (the
"Company"),  we have been asked to render this  opinion in  connection  with the
Company's  Registration  Statement  on Form S-3 (the  "Registration  Statement")
being filed  contemporaneously  by the Company with the  Securities and Exchange
Commission  under the  Securities  Act of 1933, as amended,  covering  1,988,140
shares of Common  Stock,  $.001 par value,  of the Company  which are either (i)
issuable by the Company to certain  persons and  entities  upon the  exercise of
certain  options and warrants (the "Issuable  Shares") and are being  registered
for  resale  by  such  persons  and  entities;  or (ii)  shares  of  issued  and
outstanding  Common  Stock,  $.001  par  value,  of the  Company  (the  "Selling
Stockholder  Shares")  which are owned by certain  persons and  entities and are
being  registered for resale by such persons and entities.  The Issuable  Shares
and the Selling  Stockholder  Shares are collectively  referred to herein as the
"Shares".

     In  connection  with our  opinion,  we have  examined  the  Certificate  of
Incorporation  and By-Laws of the  Company,  each as amended,  the  Registration
Statement,  and certain  agreements  entered into, and  instruments and warrants
issued,  by the Company in  connection  with the issuance of the Shares.  We are
also  familiar  with  proceedings  of the Board of Directors of the Company,  or
otherwise  have relied  upon  representations  made by officers of the  Company,
relating  to the  authorization  of the  issuance  of the  Shares.  We have also
examined such other  instruments  and documents as we deemed  relevant under the
circumstances.

     For  purposes of the  opinions  expressed  below,  we have  assumed (i) the
authenticity of all documents submitted to us as originals,  (ii) the conformity
to the  originals  of all  documents  submitted  as  certified,  photostatic  or
facsimile copies and the authenticity of the originals, (iii) the legal capacity
of natural persons,  (iv) the due  authorization,  execution and delivery of all
documents by all parties and the validity and binding effect thereof and (v) the
conformity to the  proceedings  of the Board of Directors of all minutes of such
proceedings and all representations, oral and





Sandata, Inc.
April 25, 1997
Page 2

written,  made by officers of the Company  with  respect  thereto.  We have also
assumed that the corporate  records  furnished to us by the Company  include all
corporate proceedings taken by the Company to date.

     Based upon and subject to the foregoing  including the assumptions made, we
are of the opinion that (i) the Selling Stockholder Shares were duly and validly
authorized  and  issued and are fully  paid and  nonassessable  shares of Common
Stock,  $.001 par value,  of the Company,  and (ii) the Issuable Shares will be,
upon  issuance  in  accordance  with the  terms of the  respective  options  and
warrants,  duly and validly authorized and issued,  fully paid and nonassessable
shares of Common Stock, .$001 par value, of the Company.

     We hereby  consent  to the use of our  opinion  as  herein  set forth as an
exhibit  to the  Registration  Statement  and to the use of our name  under  the
caption  "Legal  Matters" in the Prospectus  forming a part of the  Registration
Statement.

     This opinion is as of the date hereof, and we do not undertake,  and hereby
disclaim,  any obligation to advise you of any changes in any of the matters set
forth herein.

     We are  rendering  this opinion only as to the matters  expressly set forth
herein, and no opinion should be inferred as to any other matters.

     This  opinion  is for your  exclusive  use only and is to be  utilized  and
relied upon only in connection with the matters expressly set forth herein.


                                Very truly yours,
                                
                                /s/ CERTILMAN BALIN ADLER & HYMAN, LLP

                                CERTILMAN BALIN ADLER & HYMAN, LLP