-1

I have one sample sql server DB mdf file .I need to convert the file to excel or csv.i searched but not get correct solution.Finally I found one package from python asammdf

I don't know how to do this .i am really new with python and sql server.

My try

  from asammdf import MDF, Signal
    import numpy as np

    with MDF(r'sample.mdf') as mdf_file:
        # do something
    export('csv', mdf_file, oned_as)

And i got Error

File "test.py", line 6
    export('csv', mdf_file, oned_as)
         ^
IndentationError: expected an indented block

If any one give me correction.Or else please guide me how to convert mdf to excel or csv some other with windows related.basically i m in Linux platform

prasanth
  • 22,145
  • 4
  • 29
  • 53

1 Answers1

0

asammdf deals with automotive Measurement Data Format (see https://www.asam.net/standards/detail/mdf)

You need to look for another package that implements sql mdf files

danielhrisca
  • 665
  • 1
  • 5
  • 11
  • As for your script error: the statements from the with block need to be indented. Python uses indentation to delimit the blocks – danielhrisca Mar 21 '19 at 22:35