in

System.Data.SQLite

An open-source, enhanced version of the SQLite database engine for Windows

Zip/Unzip database results in unreadable DB... any tips?

Last post 04-30-2008 10:18 AM by dana. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 04-29-2008 2:26 PM

    • dana
    • Top 500 Contributor
    • Joined on 04-29-2008
    • Posts 2

    Zip/Unzip database results in unreadable DB... any tips?

    Hi Guys,

    I'm writing a little app in C# that zips up a bunch of project files, faciliates sending those files to another user/location, adn then unzips the files in the correct directory structure at its destination. I'm using a reference to the Visual J# Library (vjslib.dll) to zip the files. All the other files seem to zip and unzip fine, but when I try to open the unzipped sqlite database, I get the error: "File that is opened is not a database file" and "file is encrypted or is not a database file". 

    When trying to open the db with an editor like SQLite2008Pro I get the same error. Any ideas on how to check what the problem might be, or has anyone done this before successfully?

    I hope this is an OK place to post this question.

    Thanks!
    Dana

  • 04-30-2008 5:01 AM In reply to

    Re: Zip/Unzip database results in unreadable DB... any tips?

     are you encrypting the file on the source computer?

  • 04-30-2008 10:18 AM In reply to

    • dana
    • Top 500 Contributor
    • Joined on 04-29-2008
    • Posts 2

    Re: Zip/Unzip database results in unreadable DB... any tips?

    Nope, or at least not as far as I know. Is encrypted the default state? I am doing a simple open or creation of a database. 

     string connection_string = "Data Source=\"" + projectpath + "\\"+ GetProjectDBName(projectpath) + ".db\";New=True;UTF8Encoding=True;Version=3;providerName=\"System.Data.SQLite\"";
                conn = new SQLiteConnection(connection_string);
                conn.Open();

     

    And then I zip all the contents of a certain directory in one place, and then unpack it in another. Hmm.

    Thanks again.
    Dana

Page 1 of 1 (3 items)
Powered by Community Server (Commercial Edition), by Telligent Systems