Android Question SQLlite to csv and Dbutils

Discussion in 'Android Questions' started by Tom1s, Jun 25, 2015.

  1. Tom1s

    Tom1s Member Licensed User

    Hi

    I tried this two different ways but no success. With cursor and with dbutils.
    In log there is this:
    mlist(ArrayList) [[Ljava.lang.String;@42269508]

    and the row in the file is full of strange symbols.



    Code:
    Dim mlist As List
    mlist.Initialize
    mlist=DBUtils.ExecuteMemoryTable(SQL1,
    "Select ID1,ID2,GPSLat,GPSLon FROM table where status=3",Null,0)
    Log("mlist" & mlist)
    Dim su As StringUtils
    su.SaveCSV(
    File.DirInternal,"marker_data.csv","|",mlist)
     
    Last edited: Jun 25, 2015
  2. Erel

    Erel Administrator Staff Member Licensed User

    Your code looks correct.

    What is the output of:
    Log(File.ReadString(File.DirInternal,"marker_data.csv")) ?
     
  3. Tom1s

    Tom1s Member Licensed User

    It looks ok! There was left a row in the file and it tried to owerwrite it. I have to put some clean all or file replace tms.
    Now it works.
    Thanks
     
    Last edited: Jun 25, 2015
Loading...