System.Data.SQLite
Check-in [faaaeb7bd7]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:1.0.56.0
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | sourceforge
Files: files | file ages | folders
SHA1: faaaeb7bd77a6fd51ac37a9dd511b79aa1bd28b9
User & Date: rmsimpson 2008-08-11 21:12:05
Context
2008-09-02
15:46
pre 1.0.59.0 check-in: c0dab1edea user: rmsimpson tags: sourceforge
2008-08-11
21:12
1.0.56.0 check-in: faaaeb7bd7 user: rmsimpson tags: sourceforge
2008-08-08
05:42
1.0.56.0 beta check-in: 85ed84191d user: rmsimpson tags: sourceforge
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to Doc/Extra/dbfactorysupport.html.

93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
<configuration>
  <system.data>
    <DbProviderFactories>
      <remove invariant="System.Data.SQLite"/>
      <add name="SQLite Data Provider" invariant="System.Data.SQLite" 
           description=".Net Framework Data Provider for SQLite"
           type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite,
                 Version=1.0.55.0, Culture=neutral,
                 PublicKeyToken=db937bc2d44ff139"/>
    </DbProviderFactories>
  </system.data>
</configuration>
</pre>
      </div>
      <p>







|







93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
&lt;configuration&gt;
  &lt;system.data&gt;
    &lt;DbProviderFactories&gt;
      &lt;remove invariant="System.Data.SQLite"/&gt;
      &lt;add name="SQLite Data Provider" invariant="System.Data.SQLite" 
           description=".Net Framework Data Provider for SQLite"
           type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite,
                 Version=1.0.56.0, Culture=neutral,
                 PublicKeyToken=db937bc2d44ff139"/&gt;
    &lt;/DbProviderFactories&gt;
  &lt;/system.data&gt;
&lt;/configuration&gt;
</pre>
      </div>
      <p>

Changes to Doc/Extra/lang_expr.html.

666
667
668
669
670
671
672







673
674
675
676
677
678
679
          </tr>
          <tr>
            <td align="right" width="1%" nowrap>
              random(*)</td>
            <td valign="top">
              Return a pseudo-random integer between -9223372036854775808 and +9223372036854775807.</td>
          </tr>







          <tr>
            <td align="right" width="1%" nowrap>
              replicate(<i>X</i>,<i>Y</i>)</td>
            <td valign="top">
              Return the concatenation of string <i>X</i> repeated <i>Y</i> times</td>
          </tr>
          <tr>







>
>
>
>
>
>
>







666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
          </tr>
          <tr>
            <td align="right" width="1%" nowrap>
              random(*)</td>
            <td valign="top">
              Return a pseudo-random integer between -9223372036854775808 and +9223372036854775807.</td>
          </tr>
          <tr>
            <td align="right" width="1%" nowrap>
              replace(<i>X</i>,<i>Y</i>,<i>Z</i>)</td>
            <td valign="top">
              Replace all occurances of <i>Y</i> inside string <i>X</i> with the replacement 
              text <i>Z</i>.&nbsp; Case-sensitive.</td>
          </tr>
          <tr>
            <td align="right" width="1%" nowrap>
              replicate(<i>X</i>,<i>Y</i>)</td>
            <td valign="top">
              Return the concatenation of string <i>X</i> repeated <i>Y</i> times</td>
          </tr>
          <tr>

Changes to Doc/Extra/version.html.

51
52
53
54
55
56
57

















58
59
60
61
62
63
64
          </td>
        </tr>
      </table>
    </div>
    <div id="mainSection">
    <div id="mainBody">
    <h1 class="heading">Version History</h1>

















    <p><b>1.0.55.0 - August 6, 2008</b></p>
    <ul>
      <li>Code merge with SQLite 3.6.1</li>
      <li>Added support for the user-contributed extension-functions at
        <a href="http://www.sqlite.org/contrib">http://www.sqlite.org/contrib</a>.&nbsp; 
        Feel free to override any of them with your own implementation.&nbsp; The new 
        functions are: <i>acos, asin, atan, atn2, atan2, acosh, asinh, atanh, 







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
          </td>
        </tr>
      </table>
    </div>
    <div id="mainSection">
    <div id="mainBody">
    <h1 class="heading">Version History</h1>
    <p><b>1.0.56.0 - August 11, 2008</b></p>
    <ul>
      <li>Fixed a bug in the table designer when designing new tables, wherein you had to 
        save the table first before being able to create indexes and foreign keys.</li>
      <li>Tweaks to decimal type handling.&nbsp; The &#39;decimal&#39; type can&#39;t be represented 
        by Int64 or Double (without loss of precision) in SQLite, so we have to fudge it 
        by treating it like a string and converting it back and forth in the provider.&nbsp; 
        Unfortunately backing it to the db as a string causes sorting problems.&nbsp; 
        See <a href="http://sqlite.phxsoftware.com/forums/p/1296/5595.aspx#5595">this 
        post</a> 
        for details on using a custom collation sequence to overcome the sorting issue arising from this patch.</li>
      <li>Minor tweaks and bugfixes to the test program and the provider.</li>
      <li>More adjustments to make the managed-only version of the provider run and pass 
        all tests on Mono.</li>
      <li>LINQ to Entities bits heavily updated and compiled against VS2008 SP1 RTM.&nbsp; SQLite 
        LINQ support is still considered beta.</li>
    </ul>
    <p><b>1.0.55.0 - August 6, 2008</b></p>
    <ul>
      <li>Code merge with SQLite 3.6.1</li>
      <li>Added support for the user-contributed extension-functions at
        <a href="http://www.sqlite.org/contrib">http://www.sqlite.org/contrib</a>.&nbsp; 
        Feel free to override any of them with your own implementation.&nbsp; The new 
        functions are: <i>acos, asin, atan, atn2, atan2, acosh, asinh, atanh, 

Changes to Doc/Extra/welcome.html.

88
89
90
91
92
93
94
95
96


97
98
99
100
101
102
103
      <p>This SQLite provider implements every feature of the underlying SQLite 
        database engine without omission. Here's a brief summary:</p>
      <UL>
        <LI>
        Written from scratch on VS2005/2008 specifically for ADO.NET 2.0, implenting all the
        base classes and features recently introduced in the framework, including automatic
        transaction enlistment.<li>Supports the Full and Compact .NET Framework, as well as
          native C/C++ development.&nbsp; 100% binary compatible with the original sqlite3.dll.
        </li>


        <li>
        On the Compact Framework, it is faster than Sql Server Mobile.
          SQLite's installed size is a fraction of Sql Mobile's. It uses less memory at runtime,
          runs queries faster, and has a smaller database file size as well. </li>
        <li>Encrypted database support.&nbsp; Encrypted databases are fully encrypted and
          support both binary and cleartext password types. </li>
        <li>Visual Studio 2005/2008 Design-Time Support.&nbsp; You can add a SQLite 







|
|
>
>







88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
      <p>This SQLite provider implements every feature of the underlying SQLite 
        database engine without omission. Here's a brief summary:</p>
      <UL>
        <LI>
        Written from scratch on VS2005/2008 specifically for ADO.NET 2.0, implenting all the
        base classes and features recently introduced in the framework, including automatic
        transaction enlistment.<li>Supports the Full and Compact .NET Framework, as well as
          native C/C++ development.&nbsp; 100% binary compatible with the original sqlite3.dll.</li>
        <li>Full support for Mono via a &quot;managed only&quot; provider that runs against the 
          official SQLite 3.6.1 or higher library.</li>
        <li>Full Entity Framework support (ADO.NET 3.5 SP1)</li>
        <li>
        On the Compact Framework, it is faster than Sql Server Mobile.
          SQLite's installed size is a fraction of Sql Mobile's. It uses less memory at runtime,
          runs queries faster, and has a smaller database file size as well. </li>
        <li>Encrypted database support.&nbsp; Encrypted databases are fully encrypted and
          support both binary and cleartext password types. </li>
        <li>Visual Studio 2005/2008 Design-Time Support.&nbsp; You can add a SQLite 

Changes to Doc/SQLite.NET.chm.

cannot compute difference between binary files

Changes to SQLite.Designer/ChangeScriptDialog.Designer.cs.

29
30
31
32
33
34
35




36
37
38
39
40



41
42
43
44
45
46
47
..
57
58
59
60
61
62
63

64
65
66
67
68
69
70
71
72
73
74

75
76
77
78
79
80
81
82
83
84
85

86
87
88
89
90
91
92
93
94



























































95
96
97
98
99
100
101



102
103
104
105
106
107
108
109
110
111
112
113
114



115
116
117
118
119
120
121
122




123
124
125
    private void InitializeComponent()
    {
      System.Windows.Forms.PictureBox pictureBox1;
      System.Windows.Forms.Label label1;
      System.Windows.Forms.Button noButton;
      System.Windows.Forms.Button yesButton;
      this._script = new System.Windows.Forms.RichTextBox();




      pictureBox1 = new System.Windows.Forms.PictureBox();
      label1 = new System.Windows.Forms.Label();
      noButton = new System.Windows.Forms.Button();
      yesButton = new System.Windows.Forms.Button();
      ((System.ComponentModel.ISupportInitialize)(pictureBox1)).BeginInit();



      this.SuspendLayout();
      // 
      // pictureBox1
      // 
      pictureBox1.Image = global::SQLite.Designer.VSPackage.info;
      pictureBox1.Location = new System.Drawing.Point(13, 13);
      pictureBox1.Name = "pictureBox1";
................................................................................
      label1.Name = "label1";
      label1.Size = new System.Drawing.Size(200, 13);
      label1.TabIndex = 1;
      label1.Text = "Do you want to save this script to a file?";
      // 
      // noButton
      // 

      noButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
      noButton.Location = new System.Drawing.Point(445, 362);
      noButton.Name = "noButton";
      noButton.Size = new System.Drawing.Size(75, 25);
      noButton.TabIndex = 3;
      noButton.Text = "&No";
      noButton.UseVisualStyleBackColor = true;
      noButton.Click += new System.EventHandler(this.noButton_Click);
      // 
      // yesButton
      // 

      yesButton.Location = new System.Drawing.Point(364, 362);
      yesButton.Name = "yesButton";
      yesButton.Size = new System.Drawing.Size(75, 25);
      yesButton.TabIndex = 4;
      yesButton.Text = "&Yes";
      yesButton.UseVisualStyleBackColor = true;
      yesButton.Click += new System.EventHandler(this.yesButton_Click);
      // 
      // _script
      // 
      this._script.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;

      this._script.Font = new System.Drawing.Font("Courier New", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
      this._script.Location = new System.Drawing.Point(12, 76);
      this._script.Name = "_script";
      this._script.ReadOnly = true;
      this._script.Size = new System.Drawing.Size(508, 280);
      this._script.TabIndex = 2;
      this._script.Text = "";
      this._script.WordWrap = false;
      // 



























































      // ChangeScriptDialog
      // 
      this.AcceptButton = yesButton;
      this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
      this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
      this.CancelButton = noButton;
      this.ClientSize = new System.Drawing.Size(532, 399);



      this.Controls.Add(yesButton);
      this.Controls.Add(noButton);
      this.Controls.Add(this._script);
      this.Controls.Add(label1);
      this.Controls.Add(pictureBox1);
      this.Font = new System.Drawing.Font("MS Shell Dlg 2", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
      this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
      this.MaximizeBox = false;
      this.MinimizeBox = false;
      this.Name = "ChangeScriptDialog";
      this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
      this.Text = "Save Change Script";
      ((System.ComponentModel.ISupportInitialize)(pictureBox1)).EndInit();



      this.ResumeLayout(false);
      this.PerformLayout();

    }

    #endregion

    private System.Windows.Forms.RichTextBox _script;





  }
}







>
>
>
>





>
>
>







 







>











>











>

|


|




>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







>
>
>


<


|
<
<
<


|

>
>
>








>
>
>
>



29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
..
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175

176
177
178



179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
    private void InitializeComponent()
    {
      System.Windows.Forms.PictureBox pictureBox1;
      System.Windows.Forms.Label label1;
      System.Windows.Forms.Button noButton;
      System.Windows.Forms.Button yesButton;
      this._script = new System.Windows.Forms.RichTextBox();
      this._splitter = new System.Windows.Forms.SplitContainer();
      this._show = new System.Windows.Forms.LinkLabel();
      this._original = new System.Windows.Forms.RichTextBox();
      this._saveOrig = new System.Windows.Forms.CheckBox();
      pictureBox1 = new System.Windows.Forms.PictureBox();
      label1 = new System.Windows.Forms.Label();
      noButton = new System.Windows.Forms.Button();
      yesButton = new System.Windows.Forms.Button();
      ((System.ComponentModel.ISupportInitialize)(pictureBox1)).BeginInit();
      this._splitter.Panel1.SuspendLayout();
      this._splitter.Panel2.SuspendLayout();
      this._splitter.SuspendLayout();
      this.SuspendLayout();
      // 
      // pictureBox1
      // 
      pictureBox1.Image = global::SQLite.Designer.VSPackage.info;
      pictureBox1.Location = new System.Drawing.Point(13, 13);
      pictureBox1.Name = "pictureBox1";
................................................................................
      label1.Name = "label1";
      label1.Size = new System.Drawing.Size(200, 13);
      label1.TabIndex = 1;
      label1.Text = "Do you want to save this script to a file?";
      // 
      // noButton
      // 
      noButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
      noButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
      noButton.Location = new System.Drawing.Point(445, 362);
      noButton.Name = "noButton";
      noButton.Size = new System.Drawing.Size(75, 25);
      noButton.TabIndex = 3;
      noButton.Text = "&No";
      noButton.UseVisualStyleBackColor = true;
      noButton.Click += new System.EventHandler(this.noButton_Click);
      // 
      // yesButton
      // 
      yesButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
      yesButton.Location = new System.Drawing.Point(364, 362);
      yesButton.Name = "yesButton";
      yesButton.Size = new System.Drawing.Size(75, 25);
      yesButton.TabIndex = 4;
      yesButton.Text = "&Yes";
      yesButton.UseVisualStyleBackColor = true;
      yesButton.Click += new System.EventHandler(this.yesButton_Click);
      // 
      // _script
      // 
      this._script.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
      this._script.Dock = System.Windows.Forms.DockStyle.Fill;
      this._script.Font = new System.Drawing.Font("Courier New", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
      this._script.Location = new System.Drawing.Point(0, 0);
      this._script.Name = "_script";
      this._script.ReadOnly = true;
      this._script.Size = new System.Drawing.Size(508, 134);
      this._script.TabIndex = 2;
      this._script.Text = "";
      this._script.WordWrap = false;
      // 
      // _splitter
      // 
      this._splitter.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
                  | System.Windows.Forms.AnchorStyles.Left)
                  | System.Windows.Forms.AnchorStyles.Right)));
      this._splitter.IsSplitterFixed = true;
      this._splitter.Location = new System.Drawing.Point(12, 80);
      this._splitter.Name = "_splitter";
      this._splitter.Orientation = System.Windows.Forms.Orientation.Horizontal;
      // 
      // _splitter.Panel1
      // 
      this._splitter.Panel1.Controls.Add(this._original);
      this._splitter.Panel1MinSize = 0;
      // 
      // _splitter.Panel2
      // 
      this._splitter.Panel2.Controls.Add(this._script);
      this._splitter.Panel2MinSize = 0;
      this._splitter.Size = new System.Drawing.Size(508, 276);
      this._splitter.SplitterDistance = 138;
      this._splitter.TabIndex = 5;
      // 
      // _show
      // 
      this._show.AutoSize = true;
      this._show.Location = new System.Drawing.Point(12, 64);
      this._show.Name = "_show";
      this._show.Size = new System.Drawing.Size(118, 13);
      this._show.TabIndex = 7;
      this._show.TabStop = true;
      this._show.Tag = "<< &Hide original script";
      this._show.Text = "&Show original script >>";
      this._show.LinkClicked += new System.Windows.Forms.LinkLabelLinkClickedEventHandler(this._show_LinkClicked);
      // 
      // _original
      // 
      this._original.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
      this._original.Dock = System.Windows.Forms.DockStyle.Fill;
      this._original.Font = new System.Drawing.Font("Courier New", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
      this._original.Location = new System.Drawing.Point(0, 0);
      this._original.Name = "_original";
      this._original.ReadOnly = true;
      this._original.Size = new System.Drawing.Size(508, 138);
      this._original.TabIndex = 3;
      this._original.Text = "";
      this._original.WordWrap = false;
      // 
      // _saveOrig
      // 
      this._saveOrig.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
      this._saveOrig.AutoSize = true;
      this._saveOrig.Location = new System.Drawing.Point(183, 367);
      this._saveOrig.Name = "_saveOrig";
      this._saveOrig.Size = new System.Drawing.Size(175, 17);
      this._saveOrig.TabIndex = 8;
      this._saveOrig.Text = "Save &original SQL with changes";
      this._saveOrig.UseVisualStyleBackColor = true;
      // 
      // ChangeScriptDialog
      // 
      this.AcceptButton = yesButton;
      this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
      this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
      this.CancelButton = noButton;
      this.ClientSize = new System.Drawing.Size(532, 399);
      this.Controls.Add(this._saveOrig);
      this.Controls.Add(this._show);
      this.Controls.Add(this._splitter);
      this.Controls.Add(yesButton);
      this.Controls.Add(noButton);

      this.Controls.Add(label1);
      this.Controls.Add(pictureBox1);
      this.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));



      this.Name = "ChangeScriptDialog";
      this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
      this.Text = "Save SQL Script";
      ((System.ComponentModel.ISupportInitialize)(pictureBox1)).EndInit();
      this._splitter.Panel1.ResumeLayout(false);
      this._splitter.Panel2.ResumeLayout(false);
      this._splitter.ResumeLayout(false);
      this.ResumeLayout(false);
      this.PerformLayout();

    }

    #endregion

    private System.Windows.Forms.RichTextBox _script;
    private System.Windows.Forms.LinkLabel _show;
    private System.Windows.Forms.RichTextBox _original;
    private System.Windows.Forms.SplitContainer _splitter;
    private System.Windows.Forms.CheckBox _saveOrig;

  }
}

Changes to SQLite.Designer/ChangeScriptDialog.cs.

15
16
17
18
19
20
21

22
23
24
25
26
27
28

















29
30
31
32
33
34
35
..
44
45
46
47
48
49
50
51
52







53





54
55
56





57













  using System.Text;
  using System.Windows.Forms;
  using SQLite.Designer.Design;

  public partial class ChangeScriptDialog : Form
  {
    private string _tableName;


    public ChangeScriptDialog(string tableName, string script)
    {
      _tableName = tableName;
      InitializeComponent();

      _script.Text = script;

















    }

    private void noButton_Click(object sender, EventArgs e)
    {
      DialogResult = DialogResult.Cancel;
      Close();
    }
................................................................................
        save.FileName = String.Format("{0}.sql", _tableName);
        save.Title = "Save SQLite Change Script";

        DialogResult = save.ShowDialog(this);

        if (DialogResult == DialogResult.OK)
        {
          System.IO.File.WriteAllText(save.FileName, _script.Text.Replace("\r", "").Replace("\n", "\r\n"), Encoding.UTF8);
        }







      }





      Close();
    }
  }





}




















>

|





>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







 







|
|
>
>
>
>
>
>
>
|
>
>
>
>
>


|
>
>
>
>
>
|
>
>
>
>
>
>
>
>
>
>
>
>
>
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
..
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
  using System.Text;
  using System.Windows.Forms;
  using SQLite.Designer.Design;

  public partial class ChangeScriptDialog : Form
  {
    private string _tableName;
    private static bool _defaultSave;

    public ChangeScriptDialog(string tableName, string script, string original)
    {
      _tableName = tableName;
      InitializeComponent();

      _script.Text = script;
      _original.Text = original;

      _saveOrig.Checked = _defaultSave;

      if (String.IsNullOrEmpty(original) || String.IsNullOrEmpty(script))
      {
        int increase = _splitter.Top - _show.Top;
        _show.Visible = false;
        _splitter.Top = _show.Top;
        _splitter.Height += increase;
        _saveOrig.Visible = false;
      }

      if (String.IsNullOrEmpty(script) == false)
        _splitter.Panel1Collapsed = true;
      else
        _splitter.Panel2Collapsed = true;
    }

    private void noButton_Click(object sender, EventArgs e)
    {
      DialogResult = DialogResult.Cancel;
      Close();
    }
................................................................................
        save.FileName = String.Format("{0}.sql", _tableName);
        save.Title = "Save SQLite Change Script";

        DialogResult = save.ShowDialog(this);

        if (DialogResult == DialogResult.OK)
        {
          _defaultSave = _saveOrig.Checked;

          using (System.IO.StreamWriter writer = new System.IO.StreamWriter(save.FileName, false, Encoding.UTF8))
          {
            if ((_show.Visible == true && _saveOrig.Checked == true) || (_show.Visible == false && _splitter.Panel2Collapsed == true))
            {
              if (_show.Visible == true) writer.WriteLine("/*");
              writer.WriteLine(_original.Text.Replace("\r", "").TrimEnd('\n').Replace("\n", "\r\n"));
              if (_show.Visible == true) writer.WriteLine("*/");
            }
            if (_show.Visible == true || _splitter.Panel2Collapsed == false) 
              writer.WriteLine(_script.Text.Replace("\r", "").TrimEnd('\n').Replace("\n", "\r\n"));
          }
        }
      }
      Close();
    }

    private void _show_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
    {
      string old = _show.Text;
      _show.Text = _show.Tag.ToString();
      _show.Tag = old;

      if (_splitter.IsSplitterFixed)
      {
        _splitter.IsSplitterFixed = false;
        _splitter.Panel1Collapsed = false;
      }
      else
      {
        _splitter.IsSplitterFixed = true;
        _splitter.Panel1Collapsed = true;
      }
    }
  }
}

Changes to SQLite.Designer/Design/Column.cs.

68
69
70
71
72
73
74






75
76
77
78
79
80
81
...
178
179
180
181
182
183
184

185
186
187
188
189
190
191
...
217
218
219
220
221
222
223

224
225
226
227
228
229
230
          string scalestr = (scale == int.MaxValue) ? "" : String.Format(",{0}", scale);
          _dataType = string.Format("{0}({1}{2})", _dataType, size, scalestr);
        }
      }
    }

    #region IHaveConnection Members







    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion
................................................................................

    [Browsable(false)]
    public virtual string ColumnName
    {
      get { return _columnName; }
      set
      {

        if (value != _columnName)
        {
          _columnName = value;
          _table.MakeDirty();
        }
      }
    }
................................................................................

    [Browsable(false)]
    public virtual string DataType
    {
      get { return _dataType; }
      set
      {

        if (value != _dataType)
        {
          _dataType = value;
          _table.MakeDirty();
        }
      }
    }







>
>
>
>
>
>







 







>







 







>







68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
...
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
...
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
          string scalestr = (scale == int.MaxValue) ? "" : String.Format(",{0}", scale);
          _dataType = string.Format("{0}({1}{2})", _dataType, size, scalestr);
        }
      }
    }

    #region IHaveConnection Members

    [Browsable(false)]
    public ViewTableBase DesignTable
    {
      get { return _table; }
    }

    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion
................................................................................

    [Browsable(false)]
    public virtual string ColumnName
    {
      get { return _columnName; }
      set
      {
        value = value.Trim();
        if (value != _columnName)
        {
          _columnName = value;
          _table.MakeDirty();
        }
      }
    }
................................................................................

    [Browsable(false)]
    public virtual string DataType
    {
      get { return _dataType; }
      set
      {
        value = value.Trim();
        if (value != _dataType)
        {
          _dataType = value;
          _table.MakeDirty();
        }
      }
    }

Changes to SQLite.Designer/Design/ForeignKey.cs.

128
129
130
131
132
133
134






135
136
137
138
139
140
141
...
353
354
355
356
357
358
359






360
361
362
363
364
365
366

    public override string ToString()
    {
      return String.Format("[{0}].[{1}].[{2}]", _catalog, _table, _column);
    }

    #region IHaveConnection Members







    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_fkey).GetConnection();
    }

    [Browsable(false)]
................................................................................
          _name = value;
          MakeDirty();
        }
      }
    }

    #region IHaveConnection Members







    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion







>
>
>
>
>
>







 







>
>
>
>
>
>







128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
...
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378

    public override string ToString()
    {
      return String.Format("[{0}].[{1}].[{2}]", _catalog, _table, _column);
    }

    #region IHaveConnection Members

    [Browsable(false)]
    public ViewTableBase DesignTable
    {
      get { return _fkey.DesignTable; }
    }

    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_fkey).GetConnection();
    }

    [Browsable(false)]
................................................................................
          _name = value;
          MakeDirty();
        }
      }
    }

    #region IHaveConnection Members

    [Browsable(false)]
    public ViewTableBase DesignTable
    {
      get { return _table; }
    }

    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion

Changes to SQLite.Designer/Design/Index.cs.

422
423
424
425
426
427
428






429
430
431
432
433
434
435
...
494
495
496
497
498
499
500






501
502
503
504
505
506
507
...
690
691
692
693
694
695
696
697
698
699

700
701
702
703

704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727


























728
729
730
731
732
733
734
...
775
776
777
778
779
780
781

782
783
784




785
786
787
788
789












790
791
792
793
794
795
796
...
799
800
801
802
803
804
805

806
807


808
809
810
811
812





813
814
815


816
817
818
    {
      get { return _parent.Table.Name; }
    }

    #endregion

    #region IHaveConnection Members







    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_parent).GetConnection();
    }

    #endregion
................................................................................
    [Description("Specifies whether this is an index or a primary key.")]
    public virtual IndexTypeEnum IndexType
    {
      get { return IndexTypeEnum.Index; }
    }

    #region IHaveConnection Members







    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion
................................................................................
      if (value == null) value = String.Empty;
      if (String.IsNullOrEmpty(value.ToString()) == true) value = String.Empty;

      string[] values = value.ToString().Split(',');
      
      // populate the list
      _list.Items.Clear();
      DataTable tbl = null;

      try

      {
        string prefix = "";
        tbl = parent.GetConnection().GetSchema("Columns", new string[] { parent.Catalog, null, parent.Name });
        if (tbl.Rows.Count == 0)

        {
          tbl.Dispose();
          tbl = null;
          prefix = "VIEW_";
          tbl = parent.GetConnection().GetSchema("ViewColumns", new string[] { parent.Catalog, null, parent.Name });
        }
        foreach (DataRow item in tbl.Rows)
        {
          // add this item with the proper check state
          CheckState check = CheckState.Unchecked;
          for (int n = 0; n < values.Length; n++)
          {
            if (values[n].Trim() == String.Format("[{0}]", item[prefix + "COLUMN_NAME"].ToString()))
            {
              check = CheckState.Checked;
              break;
            }
          }
          _list.Items.Add(item[prefix + "COLUMN_NAME"].ToString(), check);
        }
      }
      finally
      {
        if (tbl != null) tbl.Dispose();


























      }
      _list.Height = Math.Min(300, (_list.Items.Count + 1) * _list.Font.Height);

      // show the list
      _cancel = false;
      _edSvc.DropDownControl(_list);

................................................................................
      return UITypeEditorEditStyle.DropDown;
    }

    protected override void FillTreeWithData(Selector selector, ITypeDescriptorContext context, IServiceProvider provider)
    {
      base.FillTreeWithData(selector, context, provider);
      IHaveConnectionScope source = context.Instance as IHaveConnectionScope;


      if (source == null) return;





      using (DataTable table = source.GetConnection().GetSchema("Columns", new string[] { source.CatalogScope, null, source.TableScope }))
      {
        foreach (DataRow row in table.Rows)
        {
          selector.AddNode(row[3].ToString(), row[3], null);












        }
      }
    }
  }

  internal class TablesTypeEditor : ObjectSelectorEditor
  {
................................................................................
      return UITypeEditorEditStyle.DropDown;
    }

    protected override void FillTreeWithData(Selector selector, ITypeDescriptorContext context, IServiceProvider provider)
    {
      base.FillTreeWithData(selector, context, provider);
      IHaveConnectionScope source = context.Instance as IHaveConnectionScope;


      if (source == null) return;



      using (DataTable table = source.GetConnection().GetSchema("Tables", new string[] { source.CatalogScope }))
      {
        foreach (DataRow row in table.Rows)
        {





          selector.AddNode(row[2].ToString(), row[2], null);
        }
      }


    }
  }
}







>
>
>
>
>
>







 







>
>
>
>
>
>







 







<

<
>

<
<
<
>

<
<
<
<
<
<
<
<



|





|


|

|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







 







>



>
>
>
>
|
|
|
|
|
>
>
>
>
>
>
>
>
>
>
>
>







 







>


>
>





>
>
>
>
>
|


>
>



422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
...
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
...
702
703
704
705
706
707
708

709

710
711



712
713








714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
...
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
...
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
    {
      get { return _parent.Table.Name; }
    }

    #endregion

    #region IHaveConnection Members

    [Browsable(false)]
    public ViewTableBase DesignTable
    {
      get { return _parent.DesignTable; }
    }

    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_parent).GetConnection();
    }

    #endregion
................................................................................
    [Description("Specifies whether this is an index or a primary key.")]
    public virtual IndexTypeEnum IndexType
    {
      get { return IndexTypeEnum.Index; }
    }

    #region IHaveConnection Members

    [Browsable(false)]
    public ViewTableBase DesignTable
    {
      get { return _table; }
    }

    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion
................................................................................
      if (value == null) value = String.Empty;
      if (String.IsNullOrEmpty(value.ToString()) == true) value = String.Empty;

      string[] values = value.ToString().Split(',');
      
      // populate the list
      _list.Items.Clear();



      if (parent is Table)
      {



        foreach (Column c in ((Table)parent).Columns)
        {








          CheckState check = CheckState.Unchecked;
          for (int n = 0; n < values.Length; n++)
          {
            if (values[n].Trim() == String.Format("[{0}]", c.ColumnName))
            {
              check = CheckState.Checked;
              break;
            }
          }
          _list.Items.Add(c.ColumnName, check);
        }
      }
      else
      {
        try
        {
          using (DbCommand cmd = trig.GetConnection().CreateCommand())
          {
            cmd.CommandText = ((View)parent).SqlText;
            using (DbDataReader reader = cmd.ExecuteReader(CommandBehavior.SchemaOnly))
            using (DataTable tbl = reader.GetSchemaTable())
            {
              foreach (DataRow row in tbl.Rows)
              {
                CheckState check = CheckState.Unchecked;
                for (int n = 0; n < values.Length; n++)
                {
                  if (values[n].Trim() == String.Format("[{0}]", row[SchemaTableColumn.ColumnName]))
                  {
                    check = CheckState.Checked;
                    break;
                  }
                }
                _list.Items.Add(row[SchemaTableColumn.ColumnName].ToString(), check);
              }
            }
          }
        }
        catch
        {
        }
      }
      _list.Height = Math.Min(300, (_list.Items.Count + 1) * _list.Font.Height);

      // show the list
      _cancel = false;
      _edSvc.DropDownControl(_list);

................................................................................
      return UITypeEditorEditStyle.DropDown;
    }

    protected override void FillTreeWithData(Selector selector, ITypeDescriptorContext context, IServiceProvider provider)
    {
      base.FillTreeWithData(selector, context, provider);
      IHaveConnectionScope source = context.Instance as IHaveConnectionScope;
      ViewTableBase design;

      if (source == null) return;

      design = source.DesignTable;

      if (design.Name != source.TableScope)
      {
        using (DataTable table = source.GetConnection().GetSchema("Columns", new string[] { source.CatalogScope, null, source.TableScope }))
        {
          foreach (DataRow row in table.Rows)
          {
            selector.AddNode(row[3].ToString(), row[3], null);
          }
        }
      }
      else
      {
        Table tbl = design as Table;
        if (tbl != null)
        {
          foreach (Column c in tbl.Columns)
          {
            selector.AddNode(c.ColumnName, c.ColumnName, null);
          }
        }
      }
    }
  }

  internal class TablesTypeEditor : ObjectSelectorEditor
  {
................................................................................
      return UITypeEditorEditStyle.DropDown;
    }

    protected override void FillTreeWithData(Selector selector, ITypeDescriptorContext context, IServiceProvider provider)
    {
      base.FillTreeWithData(selector, context, provider);
      IHaveConnectionScope source = context.Instance as IHaveConnectionScope;
      Table design;

      if (source == null) return;

      design = source.DesignTable as Table;

      using (DataTable table = source.GetConnection().GetSchema("Tables", new string[] { source.CatalogScope }))
      {
        foreach (DataRow row in table.Rows)
        {
          bool add = true;
          if (design != null && (row[2].ToString() == design.OldName || row[2].ToString() == design.Name))
            add = false;

          if (add) 
            selector.AddNode(row[2].ToString(), row[2], null);
        }
      }
      if (design != null)
        selector.AddNode(design.Name, design.Name, null);
    }
  }
}

Changes to SQLite.Designer/Design/Table.cs.

15
16
17
18
19
20
21

22
23
24
25
26

27
28
29
30
31
32
33
...
178
179
180
181
182
183
184

185
186
187
188
189
190
191
...
279
280
281
282
283
284
285






286
287
288
289
290
291
292
...
457
458
459
460
461
462
463






464
465
466
467
468
469
470
...
531
532
533
534
535
536
537


538
539
540
541
542
543
544
  using System.Collections.Generic;
  using System.Data;
  using System.Text;
  using SQLite.Designer.Editors;

  internal abstract class ViewTableBase: IHaveConnection
  {

    public abstract string Name { get; set; }
    public abstract string Catalog { get; }
    public abstract object Triggers { get; }
    public abstract void MakeDirty();
    public abstract DbConnection GetConnection();

  }

  internal class Table : ViewTableBase, ICustomTypeDescriptor
  {
    private string _name;
    private string _oldname;
    private string _catalog;
................................................................................
          }
          n = x;
          _check.Add(builder.ToString());
        }
      }

      builder.Length = 0;

      builder.Append(_origSql);

      builder.AppendLine(";");
      foreach (Index idx in _oldindexes)
      {
        builder.AppendFormat("{0};\r\n", idx.OriginalSql);
      }
................................................................................
        {
          _name = value;
          _owner.Name = value;
          _owner.MakeDirty();
        }
      }
    }







    public override string ToString()
    {
      return String.Format("[{0}].[{1}]", Catalog, Name);
    }

    [Category("Storage")]
................................................................................
          separator = "\r\n";
        }
        builder.AppendLine();
      }

      return builder.ToString();
    }







    public override DbConnection GetConnection()
    {
      return _connection;
    }

    #region ICustomTypeDescriptor Members
................................................................................

    #endregion
  }

  internal interface IHaveConnection
  {
    DbConnection GetConnection();


  }

  internal interface IHaveConnectionScope : IHaveConnection
  {
    [Browsable(false)]
    string CatalogScope { get; }
    [Browsable(false)]







>





>







 







>







 







>
>
>
>
>
>







 







>
>
>
>
>
>







 







>
>







15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
...
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
...
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
...
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
...
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
  using System.Collections.Generic;
  using System.Data;
  using System.Text;
  using SQLite.Designer.Editors;

  internal abstract class ViewTableBase: IHaveConnection
  {
    public abstract string OldName { get; }
    public abstract string Name { get; set; }
    public abstract string Catalog { get; }
    public abstract object Triggers { get; }
    public abstract void MakeDirty();
    public abstract DbConnection GetConnection();
    public abstract ViewTableBase DesignTable { get; }
  }

  internal class Table : ViewTableBase, ICustomTypeDescriptor
  {
    private string _name;
    private string _oldname;
    private string _catalog;
................................................................................
          }
          n = x;
          _check.Add(builder.ToString());
        }
      }

      builder.Length = 0;
      builder.AppendLine("-- Original table schema");
      builder.Append(_origSql);

      builder.AppendLine(";");
      foreach (Index idx in _oldindexes)
      {
        builder.AppendFormat("{0};\r\n", idx.OriginalSql);
      }
................................................................................
        {
          _name = value;
          _owner.Name = value;
          _owner.MakeDirty();
        }
      }
    }

    [Browsable(false)]
    public override string OldName
    {
      get { return _oldname; }
    }

    public override string ToString()
    {
      return String.Format("[{0}].[{1}]", Catalog, Name);
    }

    [Category("Storage")]
................................................................................
          separator = "\r\n";
        }
        builder.AppendLine();
      }

      return builder.ToString();
    }

    [Browsable(false)]
    public override ViewTableBase DesignTable
    {
      get { return this; }
    }

    public override DbConnection GetConnection()
    {
      return _connection;
    }

    #region ICustomTypeDescriptor Members
................................................................................

    #endregion
  }

  internal interface IHaveConnection
  {
    DbConnection GetConnection();
    [Browsable(false)]
    ViewTableBase DesignTable { get; }
  }

  internal interface IHaveConnectionScope : IHaveConnection
  {
    [Browsable(false)]
    string CatalogScope { get; }
    [Browsable(false)]

Changes to SQLite.Designer/Design/Trigger.cs.

438
439
440
441
442
443
444






445
446
447
448
449
450
451

        _action = sql.Substring(startpos, endpos - startpos);
        _action = _action.TrimStart('\r').TrimStart('\n').TrimEnd('\n').TrimEnd('\r').Trim();
      }
    }

    #region IHaveConnection Members







    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion







>
>
>
>
>
>







438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457

        _action = sql.Substring(startpos, endpos - startpos);
        _action = _action.TrimStart('\r').TrimStart('\n').TrimEnd('\n').TrimEnd('\r').Trim();
      }
    }

    #region IHaveConnection Members

    [Browsable(false)]
    public ViewTableBase DesignTable
    {
      get { return _table; }
    }

    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_table).GetConnection();
    }

    #endregion

Changes to SQLite.Designer/Design/Unique.cs.

33
34
35
36
37
38
39






40
41
42
43
44
45
46
      if (row != null)
      {
        _isUnique = (row.IsNull("UNIQUE") == false) ? (bool)row["UNIQUE"] : false;
      }
    }

    #region IHaveConnection Members







    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_column).GetConnection();
    }

    #endregion







>
>
>
>
>
>







33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
      if (row != null)
      {
        _isUnique = (row.IsNull("UNIQUE") == false) ? (bool)row["UNIQUE"] : false;
      }
    }

    #region IHaveConnection Members

    [Browsable(false)]
    public ViewTableBase DesignTable
    {
      get { return _column.DesignTable; }
    }

    public DbConnection GetConnection()
    {
      return ((IHaveConnection)_column).GetConnection();
    }

    #endregion

Changes to SQLite.Designer/Design/View.cs.

115
116
117
118
119
120
121
122






123
124
125
126
127
128
129
...
242
243
244
245
246
247
248






249
250
251
252
253
254
255
        {
          _name = value;
          _owner.Name = value;
          _owner.MakeDirty();
        }
      }
    }
  






    [Category("Storage")]
    [Editor(typeof(CatalogTypeEditor), typeof(UITypeEditor))]
    [DefaultValue("main")]
    [RefreshProperties(RefreshProperties.All)]
    public override string Catalog
    {
      get { return _catalog; }
................................................................................

    object ICustomTypeDescriptor.GetPropertyOwner(PropertyDescriptor pd)
    {
      return this;
    }

    #endregion







    public override DbConnection GetConnection()
    {
      return _connection;
    }
  }
}







|
>
>
>
>
>
>







 







>
>
>
>
>
>







115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
...
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
        {
          _name = value;
          _owner.Name = value;
          _owner.MakeDirty();
        }
      }
    }

    [Browsable(false)]
    public override string OldName
    {
      get { return _oldname; }
    }

    [Category("Storage")]
    [Editor(typeof(CatalogTypeEditor), typeof(UITypeEditor))]
    [DefaultValue("main")]
    [RefreshProperties(RefreshProperties.All)]
    public override string Catalog
    {
      get { return _catalog; }
................................................................................

    object ICustomTypeDescriptor.GetPropertyOwner(PropertyDescriptor pd)
    {
      return this;
    }

    #endregion

    [Browsable(false)]
    public override ViewTableBase DesignTable
    {
      get { return this; }
    }

    public override DbConnection GetConnection()
    {
      return _connection;
    }
  }
}

Changes to SQLite.Designer/Editors/TableDesignerDoc.cs.

418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
...
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
    {
      if (pguidCmdGroup == VSConstants.GUID_VSStandardCommandSet97)
      {
        switch ((VSConstants.VSStd97CmdID)nCmdID)
        {
          case VSConstants.VSStd97CmdID.GenerateChangeScript:
            {
              using (ChangeScriptDialog dlg = new ChangeScriptDialog(_table.Name, GetChangeScript()))
              {
                dlg.ShowDialog(this);
              }
            }
            return VSConstants.S_OK;
          case VSConstants.VSStd97CmdID.PrimaryKey:
            bool newVal = IsPkSelected();
................................................................................
          case VSConstants.VSStd97CmdID.PrimaryKey:
            prgCmds[0].cmdf = (uint)(OLECMDF.OLECMDF_SUPPORTED | OLECMDF.OLECMDF_ENABLED);
            if (IsPkSelected() == true)
              prgCmds[0].cmdf |= (uint)(OLECMDF.OLECMDF_LATCHED);

            break;
          case VSConstants.VSStd97CmdID.GenerateChangeScript:
            if (_dirty == true)
            {
              prgCmds[0].cmdf = (uint)(OLECMDF.OLECMDF_SUPPORTED | OLECMDF.OLECMDF_ENABLED);
              break;
            }
            return (int)(Microsoft.VisualStudio.OLE.Interop.Constants.OLECMDERR_E_NOTSUPPORTED);
          case VSConstants.VSStd97CmdID.Cut:
            if (SelectedRows.Length > 0)







|







 







|







418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
...
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
    {
      if (pguidCmdGroup == VSConstants.GUID_VSStandardCommandSet97)
      {
        switch ((VSConstants.VSStd97CmdID)nCmdID)
        {
          case VSConstants.VSStd97CmdID.GenerateChangeScript:
            {
              using (ChangeScriptDialog dlg = new ChangeScriptDialog(_table.Name, (_dirty == true) ? GetChangeScript() : String.Empty, _table.OriginalSql))
              {
                dlg.ShowDialog(this);
              }
            }
            return VSConstants.S_OK;
          case VSConstants.VSStd97CmdID.PrimaryKey:
            bool newVal = IsPkSelected();
................................................................................
          case VSConstants.VSStd97CmdID.PrimaryKey:
            prgCmds[0].cmdf = (uint)(OLECMDF.OLECMDF_SUPPORTED | OLECMDF.OLECMDF_ENABLED);
            if (IsPkSelected() == true)
              prgCmds[0].cmdf |= (uint)(OLECMDF.OLECMDF_LATCHED);

            break;
          case VSConstants.VSStd97CmdID.GenerateChangeScript:
            if (_dirty == true || String.IsNullOrEmpty(_table.OriginalSql) == false)
            {
              prgCmds[0].cmdf = (uint)(OLECMDF.OLECMDF_SUPPORTED | OLECMDF.OLECMDF_ENABLED);
              break;
            }
            return (int)(Microsoft.VisualStudio.OLE.Interop.Constants.OLECMDERR_E_NOTSUPPORTED);
          case VSConstants.VSStd97CmdID.Cut:
            if (SelectedRows.Length > 0)

Changes to SQLite.Designer/Editors/ViewDesignerDoc.cs.

255
256
257
258
259
260
261






262
263
264
265
266
267
268
...
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
...
420
421
422
423
424
425
426

427
428
429
430
431
432
433
      return VSConstants.E_NOTIMPL;
    }

    public int RenameDocData(uint grfAttribs, IVsHierarchy pHierNew, uint itemidNew, string pszMkDocumentNew)
    {
      return VSConstants.E_NOTIMPL;
    }







    public int SaveDocData(VSSAVEFLAGS dwSave, out string pbstrMkDocumentNew, out int pfSaveCanceled)
    {
      pbstrMkDocumentNew = null; // _view.Name;
      pfSaveCanceled = 0;

      if (String.IsNullOrEmpty(_view.OriginalSql) == true)
................................................................................
            pfSaveCanceled = 1;
            return VSConstants.S_OK;
          }
          _view.Name = dlg.TableName;
        }
      }

      string query = _typeQB.InvokeMember("SqlText", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.GetProperty, null, _queryDesigner, null) as string;
      _view.SqlText = query;

      query = _view.GetSqlText();
      if (String.IsNullOrEmpty(query) == false)
      {
        using (DbTransaction trans = _view.GetConnection().BeginTransaction())
        {
          try
          {
            using (DbCommand cmd = _view.GetConnection().CreateCommand())
................................................................................
      {
        switch ((cmdid)nCmdID)
        {
          case cmdid.Triggers:
            ViewHolder holder = new ViewHolder(_view);
            _pg.SelectedObject = holder;
            _pg.SelectedGridItem = _pg.SelectedGridItem.Parent.GridItems[0];

            TriggerEditor ted = new TriggerEditor(_view);
            ted.EditValue((ITypeDescriptorContext)_pg.SelectedGridItem, (System.IServiceProvider)_pg.SelectedGridItem, _pg.SelectedGridItem.Value);
            return VSConstants.S_OK;
        }
      }









>
>
>
>
>
>







 







|
<

|







 







>







255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
...
280
281
282
283
284
285
286
287

288
289
290
291
292
293
294
295
296
...
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
      return VSConstants.E_NOTIMPL;
    }

    public int RenameDocData(uint grfAttribs, IVsHierarchy pHierNew, uint itemidNew, string pszMkDocumentNew)
    {
      return VSConstants.E_NOTIMPL;
    }

    private void CommitQueryBuilder()
    {
      string query = _typeQB.InvokeMember("SqlText", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.GetProperty, null, _queryDesigner, null) as string;
      _view.SqlText = query;
    }

    public int SaveDocData(VSSAVEFLAGS dwSave, out string pbstrMkDocumentNew, out int pfSaveCanceled)
    {
      pbstrMkDocumentNew = null; // _view.Name;
      pfSaveCanceled = 0;

      if (String.IsNullOrEmpty(_view.OriginalSql) == true)
................................................................................
            pfSaveCanceled = 1;
            return VSConstants.S_OK;
          }
          _view.Name = dlg.TableName;
        }
      }

      CommitQueryBuilder();


      string query = _view.GetSqlText();
      if (String.IsNullOrEmpty(query) == false)
      {
        using (DbTransaction trans = _view.GetConnection().BeginTransaction())
        {
          try
          {
            using (DbCommand cmd = _view.GetConnection().CreateCommand())
................................................................................
      {
        switch ((cmdid)nCmdID)
        {
          case cmdid.Triggers:
            ViewHolder holder = new ViewHolder(_view);
            _pg.SelectedObject = holder;
            _pg.SelectedGridItem = _pg.SelectedGridItem.Parent.GridItems[0];
            CommitQueryBuilder();
            TriggerEditor ted = new TriggerEditor(_view);
            ted.EditValue((ITypeDescriptorContext)_pg.SelectedGridItem, (System.IServiceProvider)_pg.SelectedGridItem, _pg.SelectedGridItem.Value);
            return VSConstants.S_OK;
        }
      }


Changes to SQLite.Interop/SQLite.Interop.rc.

49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
..
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81

/////////////////////////////////////////////////////////////////////////////
//
// Version
//

VS_VERSION_INFO VERSIONINFO
 FILEVERSION 1,0,55,0
 PRODUCTVERSION 1,0,0,0
 FILEFLAGSMASK 0x17L
#ifdef _DEBUG
 FILEFLAGS 0x1L
#else
 FILEFLAGS 0x0L
#endif
................................................................................
BEGIN
    BLOCK "StringFileInfo"
    BEGIN
        BLOCK "040904b0"
        BEGIN
            VALUE "Comments", "http://sqlite.phxsoftware.com"
            VALUE "FileDescription", "System.Data.SQLite Interop Library"
            VALUE "FileVersion", "1.0.55.0"
            VALUE "InternalName", "SQLite.Interop.DLL"
            VALUE "LegalCopyright", "Released to the public domain"
            VALUE "OriginalFilename", "SQLite3.DLL 3.6.1"
            VALUE "ProductName", "System.Data.SQLite"
            VALUE "ProductVersion", "1.0"
        END
    END







|







 







|







49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
..
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81

/////////////////////////////////////////////////////////////////////////////
//
// Version
//

VS_VERSION_INFO VERSIONINFO
 FILEVERSION 1,0,56,0
 PRODUCTVERSION 1,0,0,0
 FILEFLAGSMASK 0x17L
#ifdef _DEBUG
 FILEFLAGS 0x1L
#else
 FILEFLAGS 0x0L
#endif
................................................................................
BEGIN
    BLOCK "StringFileInfo"
    BEGIN
        BLOCK "040904b0"
        BEGIN
            VALUE "Comments", "http://sqlite.phxsoftware.com"
            VALUE "FileDescription", "System.Data.SQLite Interop Library"
            VALUE "FileVersion", "1.0.56.0"
            VALUE "InternalName", "SQLite.Interop.DLL"
            VALUE "LegalCopyright", "Released to the public domain"
            VALUE "OriginalFilename", "SQLite3.DLL 3.6.1"
            VALUE "ProductName", "System.Data.SQLite"
            VALUE "ProductVersion", "1.0"
        END
    END

Changes to SQLite.Interop/SQLite.Interop.vcproj.

28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
		<Configuration
			Name="Release|Win32"
			OutputDirectory="$(ConfigurationName)"
			IntermediateDirectory="$(ConfigurationName)"
			ConfigurationType="2"
			CharacterSet="2"
			ManagedExtensions="0"
			WholeProgramOptimization="3"
			>
			<Tool
				Name="VCPreBuildEventTool"
				CommandLine=""
			/>
			<Tool
				Name="VCCustomBuildTool"







|







28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
		<Configuration
			Name="Release|Win32"
			OutputDirectory="$(ConfigurationName)"
			IntermediateDirectory="$(ConfigurationName)"
			ConfigurationType="2"
			CharacterSet="2"
			ManagedExtensions="0"
			WholeProgramOptimization="1"
			>
			<Tool
				Name="VCPreBuildEventTool"
				CommandLine=""
			/>
			<Tool
				Name="VCCustomBuildTool"

Changes to SQLite.Interop/merge.h.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// This code was automatically generated from assembly
// C:\Src\SQLite.NET\System.Data.SQLite\bin\CompactFramework\System.Data.SQLite.dll

#include <windef.h>

#pragma data_seg(push,clrseg,".clr")
#pragma comment(linker, "/SECTION:.clr,ER")
  char __ph[143492] = {0}; // The number of bytes to reserve
#pragma data_seg(pop,clrseg)

typedef BOOL (WINAPI *DLLMAIN)(HANDLE, DWORD, LPVOID);
typedef struct EXTRA_STUFF
{
  DWORD dwNativeEntryPoint;
} EXTRA_STUFF, *LPEXTRA_STUFF;







|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// This code was automatically generated from assembly
// C:\Src\SQLite.NET\System.Data.SQLite\bin\CompactFramework\System.Data.SQLite.dll

#include <windef.h>

#pragma data_seg(push,clrseg,".clr")
#pragma comment(linker, "/SECTION:.clr,ER")
  char __ph[143484] = {0}; // The number of bytes to reserve
#pragma data_seg(pop,clrseg)

typedef BOOL (WINAPI *DLLMAIN)(HANDLE, DWORD, LPVOID);
typedef struct EXTRA_STUFF
{
  DWORD dwNativeEntryPoint;
} EXTRA_STUFF, *LPEXTRA_STUFF;

Changes to SQLite.Interop/merge_full.h.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// This code was automatically generated from assembly
// C:\Src\SQLite.NET\System.Data.SQLite\bin\System.Data.SQLite.dll

#include <windef.h>

#pragma data_seg(push,clrseg,".clr")
#pragma comment(linker, "/SECTION:.clr,ER")
  char __ph[157228] = {0}; // The number of bytes to reserve
#pragma data_seg(pop,clrseg)

typedef BOOL (WINAPI *DLLMAIN)(HANDLE, DWORD, LPVOID);
typedef struct EXTRA_STUFF
{
  DWORD dwNativeEntryPoint;
} EXTRA_STUFF, *LPEXTRA_STUFF;

|





|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// This code was automatically generated from assembly
// C:\Src\SQLite.NET\bin\ManagedOnly\System.Data.SQLite.dll

#include <windef.h>

#pragma data_seg(push,clrseg,".clr")
#pragma comment(linker, "/SECTION:.clr,ER")
  char __ph[155780] = {0}; // The number of bytes to reserve
#pragma data_seg(pop,clrseg)

typedef BOOL (WINAPI *DLLMAIN)(HANDLE, DWORD, LPVOID);
typedef struct EXTRA_STUFF
{
  DWORD dwNativeEntryPoint;
} EXTRA_STUFF, *LPEXTRA_STUFF;

Changes to SQLite.NET.suo.

cannot compute difference between binary files

Changes to System.Data.SQLite.Linq/AssemblyInfo.cs.

29
30
31
32
33
34
35
36
//      Build Number
//      Revision
//
// You can specify all the values or you can default the Build and Revision Numbers 
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.0.36.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]







|
29
30
31
32
33
34
35
36
//      Build Number
//      Revision
//
// You can specify all the values or you can default the Build and Revision Numbers 
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.0.36.0")]
[assembly: AssemblyFileVersion("2.0.36.0")]

Changes to System.Data.SQLite.Linq/Resources/SQLiteProviderServices.ProviderManifest.xml.

240
241
242
243
244
245
246
247
248
249


250
251
252
253
254




255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292







293
294
295


296





























297











298
299
300
301











302
303
304
305
306




307
308
309
310
311
312
313
...
365
366
367
368
369
370
371
372
373
374
375
376

377
378
379
380
381
382

383
384
385
386

387
388
389
390
391

392
393
394
395
396
397

398
399

400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
...
704
705
706
707
708
709
710







































































































































































































































































711
712
713
      <Parameter Name="arg" Type="Collection(Int32)" Mode="In" />
    </Function>
    <Function Name="SUM" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Collection(Int64)" Mode="In" />
    </Function>
    <Function Name="SUM" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Decimal" />
      <Parameter Name="arg" Type="Collection(Decimal)" Mode="In" />
    </Function>


    <Function Name="SUM" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Collection(Double)" Mode="In" />
    </Function>






    <!-- TOTAL -->
    <Function Name="TOTAL" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Collection(Int32)" Mode="In" />
    </Function>
    <Function Name="TOTAL" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Collection(Int64)" Mode="In" />
    </Function>
    <Function Name="TOTAL" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Decimal" />
      <Parameter Name="arg" Type="Collection(Decimal)" Mode="In" />
    </Function>
    <Function Name="TOTAL" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Collection(Double)" Mode="In" />
    </Function>




    <!-- END AGGREGATES ############################################# -->

    <!-- Begin Scalars http://www.sqlite.org/lang_corefunc.html -->

    <Function Name="ABS" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ABS" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Int64" Mode="In" />
    </Function>
    <Function Name="ABS" BuiltIn="true">
      <ReturnType Type="Decimal" />
      <Parameter Name="arg" Type="Decimal" Mode="In" />
    </Function>







    <Function Name="ABS" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />


    </Function>









































    <Function Name="HEX" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="arg" Type="Binary" Mode="In" />
    </Function>












    <Function Name="LENGTH" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="string_expression" Type="String" Mode="In" />
    </Function>





    <!-- LOWER( str ) 
            str: char, nchar, varchar, nvarchar, varchar(max), nvarchar(max)
            returns: varchar, nvarchar   
        -->
    <Function Name="LOWER" BuiltIn="true">
      <ReturnType Type="String" />
................................................................................
    <Function Name="REPLACE" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="strTarget" Type="String"  Mode="In" />
      <Parameter Name="strSearch" Type="String"  Mode="In" />
      <Parameter Name="strReplacement" Type="String"  Mode="In" />
    </Function>

    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="numeric_expression" Type="Int32" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
    </Function>

    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="numeric_expression" Type="Int64" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">

      <ReturnType Type="Decimal" />
      <Parameter Name="numeric_expression" Type="Decimal" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
    </Function>

    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="numeric_expression" Type="Double" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
    </Function>

    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="numeric_expression" Type="Int32" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
      <Parameter Name="function" Type="Int32" Mode="In" />
    </Function>

    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int64" />

      <Parameter Name="numeric_expression" Type="Int64" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
      <Parameter Name="function" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Decimal" />
      <Parameter Name="numeric_expression" Type="Decimal" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
      <Parameter Name="function" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="numeric_expression" Type="Double" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
      <Parameter Name="function" Type="Int32" Mode="In" />
    </Function>

    <Function Name="RTRIM" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="str" Type="String" Mode="In" />
    </Function>
    <Function Name="RTRIM" BuiltIn="true">
................................................................................
    <Function Name="CURRENT_DATE" BuiltIn="true" NiladicFunction="true">
      <ReturnType Type="DateTime" />
    </Function>
    <Function Name="CURRENT_TIMESTAMP" BuiltIn="true" NiladicFunction="true">
      <ReturnType Type="DateTime" />
    </Function>








































































































































































































































































    <!-- END SYSTEM FUNCTIONS ####################################### -->
  </Functions>
</ProviderManifest>







|
|

>
>
|




>
>
>
>










<
<
<
<




<
<
<














|
|

>
>
>
>
>
>
>
|
|
<
>
>

>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

>
>
>
>
>
>
>
>
>
>
>




>
>
>
>
>
>
>
>
>
>
>





>
>
>
>







 







|
|
|
|
<
>
|
|
|
|

<
>
|
|
|
<
>
|
|
|
<

>
|
|
|
|
<
<
>
|
|
>
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<







 







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>



240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270




271
272
273
274



275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300

301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
...
427
428
429
430
431
432
433
434
435
436
437

438
439
440
441
442
443

444
445
446
447

448
449
450
451

452
453
454
455
456
457


458
459
460
461
462














463
464
465
466
467
468
469
...
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
      <Parameter Name="arg" Type="Collection(Int32)" Mode="In" />
    </Function>
    <Function Name="SUM" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Collection(Int64)" Mode="In" />
    </Function>
    <Function Name="SUM" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Collection(Double)" Mode="In" />
    </Function>

    <!-- STDEV -->
    <Function Name="STDEV" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Collection(Double)" Mode="In" />
    </Function>

    <Function Name="STDEV" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Collection(Decimal)" Mode="In" />
    </Function>

    <!-- TOTAL -->
    <Function Name="TOTAL" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Collection(Int32)" Mode="In" />
    </Function>
    <Function Name="TOTAL" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Collection(Int64)" Mode="In" />
    </Function>




    <Function Name="TOTAL" Aggregate="true" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Collection(Double)" Mode="In" />
    </Function>




    <!-- END AGGREGATES ############################################# -->

    <!-- Begin Scalars http://www.sqlite.org/lang_corefunc.html -->

    <Function Name="ABS" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ABS" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Int64" Mode="In" />
    </Function>
    <Function Name="ABS" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- CHARINDEX( strSearch, strTarget [, startLocation ] )
                strSearch: character expression
                strTarget: character expression
                startLocation: tinyint, smallint, int, bigint
                returns: int, bigint   
        -->
    <Function Name="CHARINDEX" BuiltIn="true">
      <ReturnType Type="Int32" />

      <Parameter Name="strSearch" Type="String" Mode="In" />
      <Parameter Name="strTarget" Type="String" Mode="In" />
    </Function>
    <Function Name="CHARINDEX" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="strSearch" Type="Binary" Mode="In" />
      <Parameter Name="strTarget" Type="Binary" Mode="In" />
    </Function>
    <Function Name="CHARINDEX" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="strSearch" Type="String" Mode="In" />
      <Parameter Name="strTarget" Type="String" Mode="In" />
      <Parameter Name="startLocation" Type="Int32" Mode="In" />
    </Function>
    <Function Name="CHARINDEX" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="strSearch" Type="Binary" Mode="In" />
      <Parameter Name="strTarget" Type="Binary" Mode="In" />
      <Parameter Name="startLocation" Type="Int32" Mode="In" />
    </Function>
    <Function Name="CHARINDEX" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="strSearch" Type="String" Mode="In" />
      <Parameter Name="strTarget" Type="String" Mode="In" />
      <Parameter Name="startLocation" Type="Int64" Mode="In" />
    </Function>
    <Function Name="CHARINDEX" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="strSearch" Type="Binary" Mode="In" />
      <Parameter Name="strTarget" Type="Binary" Mode="In" />
      <Parameter Name="startLocation" Type="Int64" Mode="In" />
    </Function>

    <!-- DIFFERENCE( str1, str2 ) 
            str1: varchar
            str2: varchar
            returns: int   
        -->
    <Function Name="DIFFERENCE" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="str1" Type="String" Mode="In" />
      <Parameter Name="str2" Type="String" Mode="In" />
    </Function>

    <Function Name="HEX" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="arg" Type="Binary" Mode="In" />
    </Function>

    <!-- LEFT( str, count ) 
                str: char, nchar, varchar, nvarchar, varchar(max), nvarchar(max)
                count: tinyint, smallint, int, bigint
                returns: varchar, nvarchar
        -->
    <Function Name="LEFTSTR" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="str" Type="String" Mode="In" />
      <Parameter Name="count" Type="Int64" Mode="In" />
    </Function>

    <Function Name="LENGTH" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="string_expression" Type="String" Mode="In" />
    </Function>
    <Function Name="LENGTH" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="string_expression" Type="Binary" Mode="In" />
    </Function>

    <!-- LOWER( str ) 
            str: char, nchar, varchar, nvarchar, varchar(max), nvarchar(max)
            returns: varchar, nvarchar   
        -->
    <Function Name="LOWER" BuiltIn="true">
      <ReturnType Type="String" />
................................................................................
    <Function Name="REPLACE" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="strTarget" Type="String"  Mode="In" />
      <Parameter Name="strSearch" Type="String"  Mode="In" />
      <Parameter Name="strReplacement" Type="String"  Mode="In" />
    </Function>

    <!-- REPLICATE( strSource, count )
            strSource: varchar, nvarchar
            count: tinyint, smallint, int
            returns: varchar, nvarchar   

        -->
    <Function Name="REPLICATE" BuiltIn="true">
      <ReturnType Type="String"  />
      <Parameter Name="strTarget" Type="String" Mode="In" />
      <Parameter Name="count" Type="Int32" Mode="In" />
    </Function>


    <!-- REVERSE( arg ) 
            arg: char, nchar, varchar, nvarchar, varchar(max), nvarchar(max)
            returns: varchar, nvarchar

        -->
    <Function Name="REVERSE" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="arg" Type="String" Mode="In" />

    </Function>

    <!-- RIGHT( atr, count ) 
                str: char, nchar, varchar, nvarchar, varchar(max), nvarchar(max)
                count: tinyint, smallint, int, bigint
                returns: varchar, nvarchar


        -->
    <Function Name="RIGHTSTR" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="str" Type="String" Mode="In" />
      <Parameter Name="count" Type="Int64" Mode="In" />














    </Function>

    <Function Name="RTRIM" BuiltIn="true">
      <ReturnType Type="String" />
      <Parameter Name="str" Type="String" Mode="In" />
    </Function>
    <Function Name="RTRIM" BuiltIn="true">
................................................................................
    <Function Name="CURRENT_DATE" BuiltIn="true" NiladicFunction="true">
      <ReturnType Type="DateTime" />
    </Function>
    <Function Name="CURRENT_TIMESTAMP" BuiltIn="true" NiladicFunction="true">
      <ReturnType Type="DateTime" />
    </Function>

    <!-- ACOS( arg )
                arg: float
                returns: float   
        -->
    <Function Name="ACOS" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg1" Type="Double" Mode="In" />
    </Function>

    <!-- ASIN( arg )
                arg: float
                returns: float   
        -->
    <Function Name="ASIN" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- ATAN( arg )
                arg: float
                returns: float   
        -->
    <Function Name="ATAN" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- ATN2( arg1, arg2 )
                arg1: float
                arg2: float
                returns: float   
        -->
    <Function Name="ATN2" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg1" Type="Double" Mode="In" />
      <Parameter Name="arg2" Type="Double" Mode="In" />
    </Function>

    <!-- CEILING( arg )
                arg: smalldatetime, datetime
                returns: int   
        -->
    <Function Name="CEILING" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Int32" Mode="In" />
    </Function>
    <Function Name="CEILING" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Int64" Mode="In" />
    </Function>
    <Function Name="CEILING" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- COS( arg )
                arg: float
                returns: float   
        -->
    <Function Name="COS" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- COT( arg )
                arg: float
                returns: float   
        -->
    <Function Name="COT" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- DEGREES( arg )
                arg: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
                returns: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
        -->
    <Function Name="DEGREES" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg1" Type="Int32" Mode="In" />
    </Function>
    <Function Name="DEGREES" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg1" Type="Int64" Mode="In" />
    </Function>
    <Function Name="DEGREES" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg1" Type="Double" Mode="In" />
    </Function>
    <!-- EXP( arg )
                arg: float
                returns: float   
        -->
    <Function Name="EXP" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- FLOOR( arg )
                arg: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
                returns: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
        -->
    <Function Name="FLOOR" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Int32" Mode="In" />
    </Function>
    <Function Name="FLOOR" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Int64" Mode="In" />
    </Function>
    <Function Name="FLOOR" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- LOG( arg )
            arg: float
            returns: float   
     -->
    <Function Name="LOG" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- LOG10( arg )
                arg: float
                returns: float   
        -->
    <Function Name="LOG10" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>
    <!-- PI( )
                returns: float   
        -->
    <Function Name="PI" BuiltIn="true">
      <ReturnType Type="Double" />
    </Function>

    <!-- POWER( x, y )
                x: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
                y: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
                returns: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
        -->
    <Function Name="POWER" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="x" Type="Int32" Mode="In" />
      <Parameter Name="y" Type="Double" Mode="In" />
    </Function>
    <Function Name="POWER" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="x" Type="Int64" Mode="In" />
      <Parameter Name="y" Type="Double" Mode="In" />
    </Function>
    <Function Name="POWER" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="x" Type="Double" Mode="In" />
      <Parameter Name="y" Type="Double" Mode="In" />
    </Function>
    
    <!-- RADIANS( arg )
                arg: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
                returns: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
        -->
    <Function Name="RADIANS" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Int32" Mode="In" />
    </Function>
    <Function Name="RADIANS" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Int64" Mode="In" />
    </Function>
    <Function Name="RADIANS" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="numeric_expression" Type="Int32" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="numeric_expression" Type="Int64" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="numeric_expression" Type="Double" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="numeric_expression" Type="Int32" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
      <Parameter Name="function" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="numeric_expression" Type="Int64" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
      <Parameter Name="function" Type="Int32" Mode="In" />
    </Function>
    <Function Name="ROUND" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="numeric_expression" Type="Double" Mode="In" />
      <Parameter Name="length" Type="Int32" Mode="In" />
      <Parameter Name="function" Type="Int32" Mode="In" />
    </Function>

    <!-- SIGN( arg )
            arg: tinyint, smallint, int, bigint, numeric, decimal, smallmoney, money, real, float
            returns: bigint, numeric, decimal, money, float
        -->
    <Function Name="SIGN" BuiltIn="true">
      <ReturnType Type="Int32" />
      <Parameter Name="arg" Type="Int32" Mode="In" />
    </Function>
    <Function Name="SIGN" BuiltIn="true">
      <ReturnType Type="Int64" />
      <Parameter Name="arg" Type="Int64" Mode="In" />
    </Function>
    <Function Name="SIGN" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- SIN( arg )
                arg: float
                returns: float   
        -->
    <Function Name="SIN" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- SQRT( arg )
                arg: float
                returns: float   
        -->
    <Function Name="SQRT" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>

    <!-- SQUARE( arg )
                arg: smalldatetime, datetime
                returns: int   
        -->
    <Function Name="SQUARE" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg1" Type="Double" Mode="In" />
    </Function>
    <!-- TAN( arg )
                arg: float
                returns: float   
        -->
    <Function Name="TAN" BuiltIn="true">
      <ReturnType Type="Double" />
      <Parameter Name="arg" Type="Double" Mode="In" />
    </Function>
    
    <!-- END SYSTEM FUNCTIONS ####################################### -->
  </Functions>
</ProviderManifest>

Changes to System.Data.SQLite.Linq/Resources/SQLiteProviderServices.StoreSchemaDefinition.ssdl.

1
2
3
4
5
6
7
8
9
<?xml version="1.0" encoding="utf-8"?>
<Schema Namespace="SQLite" Provider="System.Data.SQLite" ProviderManifestToken="ISO8601" Alias="Self" xmlns="http://schemas.microsoft.com/ado/2006/04/edm/ssdl">
  <EntityContainer Name="Schema">
    <EntitySet Name="STables" EntityType="Self.Table">
      <DefiningQuery>
        SELECT
        '[' || TABLE_NAME || ']' COLLATE NOCASE [Id]
        ,   TABLE_CATALOG [CatalogName]
        ,   TABLE_SCHEMA [SchemaName]

|







1
2
3
4
5
6
7
8
9
<?xml version="1.0" encoding="utf-8"?>
<Schema Namespace="EFSQLite" Provider="System.Data.SQLite" ProviderManifestToken="ISO8601" Alias="Self" xmlns="http://schemas.microsoft.com/ado/2006/04/edm/ssdl">
  <EntityContainer Name="Schema">
    <EntitySet Name="STables" EntityType="Self.Table">
      <DefiningQuery>
        SELECT
        '[' || TABLE_NAME || ']' COLLATE NOCASE [Id]
        ,   TABLE_CATALOG [CatalogName]
        ,   TABLE_SCHEMA [SchemaName]

Changes to System.Data.SQLite.Linq/SQL.

2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
....
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
    {
      SqlBuilder result = new SqlBuilder();
      Debug.Assert(e.Arguments.Count == 2, "Canonical datepart functions should have exactly two arguments");

      switch (sqlgen._manifest._dateFormat)
      {
        case SQLiteDateFormats.Ticks:
          result.Append(String.Format("(STRFTIME('%s', JULIANDAY({1}) - ({0} / 86400.0)) * 10000000 + 621355968000000000)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
        case SQLiteDateFormats.JulianDay:
          result.Append(String.Format("CAST(STRFTIME('%J', JULIANDAY({1}) - ({0} / 86400.0)) AS double)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
        default:
          result.Append(String.Format("STRFTIME('%Y-%m-%d %H:%M:%S', JULIANDAY({1}) - ({0} / 86400.0))", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
      }

      return result;
    }

    /// <summary>
................................................................................

      switch (sqlgen._manifest._dateFormat)
      {
        case SQLiteDateFormats.Ticks:
          result.Append(String.Format("CAST((({0} - 621355968000000000) / 10000000.0)  - (({1} - 621355968000000000) / 10000000.0) * 86400.0 AS integer)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
        default:
          result.Append(String.Format("CAST((JULIANDAY({0}) - JULIANDAY({1})) * 86400.0 AS integer)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
      }

      return result;
    }

    /// <summary>







|


|


|







 







|







2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
....
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
    {
      SqlBuilder result = new SqlBuilder();
      Debug.Assert(e.Arguments.Count == 2, "Canonical datepart functions should have exactly two arguments");

      switch (sqlgen._manifest._dateFormat)
      {
        case SQLiteDateFormats.Ticks:
          result.Append(String.Format("(STRFTIME('%s', JULIANDAY({1}) + ({0} / 86400.0)) * 10000000 + 621355968000000000)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
        case SQLiteDateFormats.JulianDay:
          result.Append(String.Format("CAST(STRFTIME('%J', JULIANDAY({1}) + ({0} / 86400.0)) AS double)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
        default:
          result.Append(String.Format("STRFTIME('%Y-%m-%d %H:%M:%S', JULIANDAY({1}) + ({0} / 86400.0))", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
      }

      return result;
    }

    /// <summary>
................................................................................

      switch (sqlgen._manifest._dateFormat)
      {
        case SQLiteDateFormats.Ticks:
          result.Append(String.Format("CAST((({0} - 621355968000000000) / 10000000.0)  - (({1} - 621355968000000000) / 10000000.0) * 86400.0 AS integer)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
        default:
          result.Append(String.Format("CAST((JULIANDAY({1}) - JULIANDAY({0})) * 86400.0 AS integer)", e.Arguments[0].Accept(sqlgen), e.Arguments[1].Accept(sqlgen)));
          break;
      }

      return result;
    }

    /// <summary>

Changes to System.Data.SQLite.Linq/System.Data.SQLite.Linq.csproj.

1
2
3
4
5
6
7
8
9
10
11
12
13
..
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>9.0.30703</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{E6BF9F74-58E2-413B-A7CE-EA653ECB728D}</ProjectGuid>
    <OutputType>Library</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>System.Data.SQLite</RootNamespace>
    <AssemblyName>System.Data.SQLite.Linq</AssemblyName>
    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
................................................................................
    <Compile Include="SQL Generation\SymbolTable.cs" />
    <Compile Include="SQL Generation\TopClause.cs" />
    <Compile Include="SQLiteProviderManifest.cs" />
    <Compile Include="SQLiteProviderServices.cs" />
  </ItemGroup>
  <ItemGroup>
    <EmbeddedResource Include="Resources\Common.ConceptualSchemaDefinition.csdl" />
    <EmbeddedResource Include="Resources\Common.ProviderManifest.xsd" />
    <EmbeddedResource Include="Resources\SQLiteProviderServices.StoreSchemaDefinition.ssdl" />
    <EmbeddedResource Include="Resources\SQLiteProviderServices.StoreSchemaMapping.msl" />
    <EmbeddedResource Include="Resources\System.Data.Resources.CodeGenerationSchema.xsd" />
    <EmbeddedResource Include="Resources\System.Data.Resources.CSDLSchema.xsd" />
    <EmbeddedResource Include="Resources\System.Data.Resources.CSMSL.xsd" />
    <EmbeddedResource Include="Resources\System.Data.Resources.EntityStoreSchemaGenerator.xsd" />
    <EmbeddedResource Include="Resources\System.Data.Resources.SSDLSchema.xsd" />
  </ItemGroup>
  <ItemGroup>
    <EmbeddedResource Include="Properties\Resources.resx">
      <Generator>ResXFileCodeGenerator</Generator>
      <LastGenOutput>Resources.Designer.cs</LastGenOutput>
    </EmbeddedResource>
    <EmbeddedResource Include="Resources\SQLiteProviderServices.ProviderManifest.xml" />





|







 







<


<
<
<
<
<







1
2
3
4
5
6
7
8
9
10
11
12
13
..
71
72
73
74
75
76
77

78
79





80
81
82
83
84
85
86
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>9.0.30729</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{E6BF9F74-58E2-413B-A7CE-EA653ECB728D}</ProjectGuid>
    <OutputType>Library</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>System.Data.SQLite</RootNamespace>
    <AssemblyName>System.Data.SQLite.Linq</AssemblyName>
    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
................................................................................
    <Compile Include="SQL Generation\SymbolTable.cs" />
    <Compile Include="SQL Generation\TopClause.cs" />
    <Compile Include="SQLiteProviderManifest.cs" />
    <Compile Include="SQLiteProviderServices.cs" />
  </ItemGroup>
  <ItemGroup>
    <EmbeddedResource Include="Resources\Common.ConceptualSchemaDefinition.csdl" />

    <EmbeddedResource Include="Resources\SQLiteProviderServices.StoreSchemaDefinition.ssdl" />
    <EmbeddedResource Include="Resources\SQLiteProviderServices.StoreSchemaMapping.msl" />





  </ItemGroup>
  <ItemGroup>
    <EmbeddedResource Include="Properties\Resources.resx">
      <Generator>ResXFileCodeGenerator</Generator>
      <LastGenOutput>Resources.Designer.cs</LastGenOutput>
    </EmbeddedResource>
    <EmbeddedResource Include="Resources\SQLiteProviderServices.ProviderManifest.xml" />

Changes to System.Data.SQLite/SQLite3.cs.

169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
...
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
            // If we've exceeded the command's timeout, give up and throw an error
            if ((uint)Environment.TickCount - starttick > timeout)
            {
              throw new SQLiteException(r, SQLiteLastError());
            }
            else
            {
              // Otherwise sleep for a random amount of time up to 250ms
              System.Threading.Thread.CurrentThread.Join(rnd.Next(1, 250));
            }
          }
        }
      }
    }

    internal override int Reset(SQLiteStatement stmt)
................................................................................
            // If we've exceeded the command's timeout, give up and throw an error
            if ((uint)Environment.TickCount - starttick > timeoutMS)
            {
              throw new SQLiteException(n, SQLiteLastError());
            }
            else
            {
              // Otherwise sleep for a random amount of time up to 250ms
              System.Threading.Thread.CurrentThread.Join(rnd.Next(1, 250));
            }
          }
        }

        if (n > 0) throw new SQLiteException(n, SQLiteLastError());

        strRemain = UTF8ToString(ptr, len);







|
|







 







|
|







169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
...
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
            // If we've exceeded the command's timeout, give up and throw an error
            if ((uint)Environment.TickCount - starttick > timeout)
            {
              throw new SQLiteException(r, SQLiteLastError());
            }
            else
            {
              // Otherwise sleep for a random amount of time up to 150ms
              System.Threading.Thread.CurrentThread.Join(rnd.Next(1, 150));
            }
          }
        }
      }
    }

    internal override int Reset(SQLiteStatement stmt)
................................................................................
            // If we've exceeded the command's timeout, give up and throw an error
            if ((uint)Environment.TickCount - starttick > timeoutMS)
            {
              throw new SQLiteException(n, SQLiteLastError());
            }
            else
            {
              // Otherwise sleep for a random amount of time up to 150ms
              System.Threading.Thread.CurrentThread.Join(rnd.Next(1, 150));
            }
          }
        }

        if (n > 0) throw new SQLiteException(n, SQLiteLastError());

        strRemain = UTF8ToString(ptr, len);

Changes to System.Data.SQLite/SQLiteCommand.cs.

561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626

    /// <summary>
    /// Execute the command and return the number of rows inserted/updated affected by it.
    /// </summary>
    /// <returns></returns>
    public override int ExecuteNonQuery()
    {
      InitializeForReader();

      int nAffected = 0;
      int x = 0;
      SQLiteStatement stmt;

      for(;;)
      {
        stmt = GetStatement(x);
        x++;
        if (stmt == null) break;

        while (_cnn._sql.Step(stmt)) ;
        _cnn._sql.Reset(stmt);
        nAffected += _cnn._sql.Changes;
      }

      return nAffected;
    }

    /// <summary>
    /// Execute the command and return the first column of the first row of the resultset
    /// (if present), or null if no resultset was returned.
    /// </summary>
    /// <returns>The first column of the first row of the first resultset from the query</returns>
    public override object ExecuteScalar()
    {
      InitializeForReader();

      int x = 0;
      object ret = null;
      SQLiteType typ = new SQLiteType();
      SQLiteStatement stmt;

      // We step through every statement in the command, but only grab the first row of the first resultset.
      // We keep going even after obtaining it.
      for (;;)
      {
        stmt = GetStatement(x);
        x++;
        if (stmt == null) break;

        if (_cnn._sql.Step(stmt) == true && ret == null)
        {
          typ.Type = SQLiteConvert.TypeNameToDbType(_cnn._sql.ColumnType(stmt, 0, out typ.Affinity));

          ret = _cnn._sql.GetValue(stmt, 0, typ);
        }
        _cnn._sql.Reset(stmt);
      }

      return ret;
    }

    /// <summary>
    /// Does nothing.  Commands are prepared as they are executed the first time, and kept in prepared state afterwards.
    /// </summary>
    public override void Prepare()
    {







|
|
|
|
<
|
<
<
<
<
<
<
<
<
<
<
<
<









|
|
|
|
<
<
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
|







561
562
563
564
565
566
567
568
569
570
571

572












573
574
575
576
577
578
579
580
581
582
583
584
585


586

















587
588
589
590
591
592
593
594

    /// <summary>
    /// Execute the command and return the number of rows inserted/updated affected by it.
    /// </summary>
    /// <returns></returns>
    public override int ExecuteNonQuery()
    {
      using (SQLiteDataReader reader = ExecuteReader(CommandBehavior.SingleRow | CommandBehavior.SingleResult))
      {
        while (reader.NextResult()) ;
        return reader.RecordsAffected;

      }












    }

    /// <summary>
    /// Execute the command and return the first column of the first row of the resultset
    /// (if present), or null if no resultset was returned.
    /// </summary>
    /// <returns>The first column of the first row of the first resultset from the query</returns>
    public override object ExecuteScalar()
    {
      using (SQLiteDataReader reader = ExecuteReader(CommandBehavior.SingleRow | CommandBehavior.SingleResult))
      {
        if (reader.Read())
          return reader[0];


      }

















      return null;
    }

    /// <summary>
    /// Does nothing.  Commands are prepared as they are executed the first time, and kept in prepared state afterwards.
    /// </summary>
    public override void Prepare()
    {

Changes to System.Data.SQLite/SQLiteConnectionStringBuilder.cs.

88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
...
490
491
492
493
494
495
496




497
498
499
500
501
502
503
504
505
506
507
508
509
          throw new NotSupportedException();

        this["version"] = value;
      }
    }

    /// <summary>
    /// Gets/Sets the synchronous mode of the connection string.  Default is "Normal".
    /// </summary>
    [DisplayName("Synchronous")]
    [Browsable(true)]
    [DefaultValue(SynchronizationModes.Normal)]
    public SynchronizationModes SyncMode
    {
      get
................................................................................
          value = att.Value;
          b = true;
        }
      }
      return b;
    }





    private void FallbackGetProperties(Hashtable propertyList)
    {
      foreach (PropertyDescriptor descriptor in TypeDescriptor.GetProperties(this, true))
      {
        if (descriptor.Name != "ConnectionString" && propertyList.ContainsKey(descriptor.DisplayName) == false)
        {
          propertyList.Add(descriptor.DisplayName, descriptor);
        }
      }
    }
  }
#endif
}







|







 







>
>
>
>













88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
...
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
          throw new NotSupportedException();

        this["version"] = value;
      }
    }

    /// <summary>
    /// Gets/Sets the synchronization mode (file flushing) of the connection string.  Default is "Normal".
    /// </summary>
    [DisplayName("Synchronous")]
    [Browsable(true)]
    [DefaultValue(SynchronizationModes.Normal)]
    public SynchronizationModes SyncMode
    {
      get
................................................................................
          value = att.Value;
          b = true;
        }
      }
      return b;
    }

    /// <summary>
    /// Fallback method for MONO, which doesn't implement DbConnectionStringBuilder.GetProperties()
    /// </summary>
    /// <param name="propertyList">The hashtable to fill with property descriptors</param>
    private void FallbackGetProperties(Hashtable propertyList)
    {
      foreach (PropertyDescriptor descriptor in TypeDescriptor.GetProperties(this, true))
      {
        if (descriptor.Name != "ConnectionString" && propertyList.ContainsKey(descriptor.DisplayName) == false)
        {
          propertyList.Add(descriptor.DisplayName, descriptor);
        }
      }
    }
  }
#endif
}

Changes to System.Data.SQLite/SQLiteDataReader.cs.

962
963
964
965
966
967
968



969
970
971
972
973
974

975
976
977
978
979
980
981
      if (_readingState == -1) // First step was already done at the NextResult() level, so don't step again, just return true.
      {
        _readingState = 0;
        return true;
      }
      else if (_readingState == 0) // Actively reading rows
      {



        if (_activeStatement._sql.Step(_activeStatement) == true)
        {
          if (_keyInfo != null)
            _keyInfo.Reset();

          return true;

        }

        _readingState = 1; // Finished reading rows
      }

      return false;
    }







>
>
>
|
|
|
|

|
>







962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
      if (_readingState == -1) // First step was already done at the NextResult() level, so don't step again, just return true.
      {
        _readingState = 0;
        return true;
      }
      else if (_readingState == 0) // Actively reading rows
      {
        // Don't read a new row if the command behavior dictates SingleRow.  We've already read the first row.
        if ((_commandBehavior & CommandBehavior.SingleRow) == 0)
        {
          if (_activeStatement._sql.Step(_activeStatement) == true)
          {
            if (_keyInfo != null)
              _keyInfo.Reset();

            return true;
          }
        }

        _readingState = 1; // Finished reading rows
      }

      return false;
    }

Changes to System.Data.SQLite/SQLiteFunction.cs.

524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
  /// User-defined functions can call the GetCollationSequence() method in this class and use it to compare strings and char arrays.
  /// </remarks>
  public class SQLiteFunctionEx : SQLiteFunction
  {
    /// <summary>
    /// Obtains the collating sequence in effect for the given function.
    /// </summary>
    /// <remarks>
    /// As an optimization, SQLite does not fill in this information when calling functions, unless the NeedCollationSequence
    /// boolean value is set to true in the SQLiteFunctionAttribute.
    /// </remarks>
    /// <returns></returns>
    protected CollationSequence GetCollationSequence()
    {
      return _base.GetCollationSequence(this, _context);
    }
  }








<
<
<
<







524
525
526
527
528
529
530




531
532
533
534
535
536
537
  /// User-defined functions can call the GetCollationSequence() method in this class and use it to compare strings and char arrays.
  /// </remarks>
  public class SQLiteFunctionEx : SQLiteFunction
  {
    /// <summary>
    /// Obtains the collating sequence in effect for the given function.
    /// </summary>




    /// <returns></returns>
    protected CollationSequence GetCollationSequence()
    {
      return _base.GetCollationSequence(this, _context);
    }
  }

Changes to bin/CompactFramework/System.Data.SQLite.DLL.

cannot compute difference between binary files

Changes to bin/CompactFramework/System.Data.SQLite.lib.

cannot compute difference between binary files

Changes to bin/CompactFramework/testce.exe.

cannot compute difference between binary files

Changes to bin/Designer/SQLite.Designer.dll.

cannot compute difference between binary files

Changes to bin/Designer/System.Data.SQLite.Linq.dll.

cannot compute difference between binary files

Changes to bin/Designer/System.Data.SQLite.Linq.pdb.

cannot compute difference between binary files

Changes to bin/Designer/install.exe.

cannot compute difference between binary files

Changes to bin/ManagedOnly/System.Data.SQLite.XML.

1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
....
2604
2605
2606
2607
2608
2609
2610






2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
            User-defined functions can call the GetCollationSequence() method in this class and use it to compare strings and char arrays.
            </remarks>
        </member>
        <member name="M:System.Data.SQLite.SQLiteFunctionEx.GetCollationSequence">
            <summary>
            Obtains the collating sequence in effect for the given function.
            </summary>
            <remarks>
            As an optimization, SQLite does not fill in this information when calling functions, unless the NeedCollationSequence
            boolean value is set to true in the SQLiteFunctionAttribute.
            </remarks>
            <returns></returns>
        </member>
        <member name="T:System.Data.SQLite.FunctionType">
            <summary>
            The type of user-defined function to declare
            </summary>
        </member>
................................................................................
            <summary>
            Helper function for retrieving values from the connectionstring
            </summary>
            <param name="keyword">The keyword to retrieve settings for</param>
            <param name="value">The resulting parameter value</param>
            <returns>Returns true if the value was found and returned</returns>
        </member>






        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.Version">
            <summary>
            Gets/Sets the default version of the SQLite engine to instantiate.  Currently the only valid value is 3, indicating version 3 of the sqlite library.
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.SyncMode">
            <summary>
            Gets/Sets the synchronous mode of the connection string.  Default is "Normal".
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.UseUTF16Encoding">
            <summary>
            Gets/Sets the encoding for the connection string.  The default is "False" which indicates UTF-8 encoding.
            </summary>
        </member>







<
<
<
<







 







>
>
>
>
>
>







|







1476
1477
1478
1479
1480
1481
1482




1483
1484
1485
1486
1487
1488
1489
....
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
            User-defined functions can call the GetCollationSequence() method in this class and use it to compare strings and char arrays.
            </remarks>
        </member>
        <member name="M:System.Data.SQLite.SQLiteFunctionEx.GetCollationSequence">
            <summary>
            Obtains the collating sequence in effect for the given function.
            </summary>




            <returns></returns>
        </member>
        <member name="T:System.Data.SQLite.FunctionType">
            <summary>
            The type of user-defined function to declare
            </summary>
        </member>
................................................................................
            <summary>
            Helper function for retrieving values from the connectionstring
            </summary>
            <param name="keyword">The keyword to retrieve settings for</param>
            <param name="value">The resulting parameter value</param>
            <returns>Returns true if the value was found and returned</returns>
        </member>
        <member name="M:System.Data.SQLite.SQLiteConnectionStringBuilder.FallbackGetProperties(System.Collections.Hashtable)">
            <summary>
            Fallback method for MONO, which doesn't implement DbConnectionStringBuilder.GetProperties()
            </summary>
            <param name="propertyList">The hashtable to fill with property descriptors</param>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.Version">
            <summary>
            Gets/Sets the default version of the SQLite engine to instantiate.  Currently the only valid value is 3, indicating version 3 of the sqlite library.
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.SyncMode">
            <summary>
            Gets/Sets the synchronization mode (file flushing) of the connection string.  Default is "Normal".
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.UseUTF16Encoding">
            <summary>
            Gets/Sets the encoding for the connection string.  The default is "False" which indicates UTF-8 encoding.
            </summary>
        </member>

Changes to bin/ManagedOnly/System.Data.SQLite.dll.

cannot compute difference between binary files

Changes to bin/System.Data.SQLite.XML.

266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
...
733
734
735
736
737
738
739





740
741
742
743
744
745
746
....
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
....
2613
2614
2615
2616
2617
2618
2619






2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
        <member name="M:System.Data.SQLite.SQLiteConnection.CreateFile(System.String)">
            <summary>
            Creates a database file.  This just creates a zero-byte file which SQLite
            will turn into a database when the file is opened properly.
            </summary>
            <param name="databaseFileName">The file to create</param>
        </member>
        <member name="M:System.Data.SQLite.SQLiteConnection.CompressFile(System.String)">
            <summary>
            On NTFS volumes, this function turns on the compression attribute for the given file.
            It must not be open or referenced at the time of the function call.
            </summary>
            <param name="databaseFileName">The file to compress</param>
        </member>
        <member name="M:System.Data.SQLite.SQLiteConnection.DecompressFile(System.String)">
            <summary>
            On NTFS volumes, this function removes the compression attribute for the given file.
            It must not be open or referenced at the time of the function call.
            </summary>
            <param name="databaseFileName">The file to decompress</param>
        </member>
        <member name="M:System.Data.SQLite.SQLiteConnection.OnStateChange(System.Data.ConnectionState)">
            <summary>
            Raises the state change event when the state of the connection changes
            </summary>
            <param name="newState">The new state.  If it is different from the previous state, an event is raised.</param>
        </member>
        <member name="M:System.Data.SQLite.SQLiteConnection.BeginTransaction(System.Data.IsolationLevel,System.Boolean)">
................................................................................
            Gets/sets the default command timeout for newly-created commands.  This is especially useful for 
            commands used internally such as inside a SQLiteTransaction, where setting the timeout is not possible.
            This can also be set in the ConnectionString with "Default Timeout"
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnection.ServerVersion">
            <summary>





            Returns the version of the underlying SQLite database engine
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnection.State">
            <summary>
            Returns the state of the connection.
            </summary>
................................................................................
            User-defined functions can call the GetCollationSequence() method in this class and use it to compare strings and char arrays.
            </remarks>
        </member>
        <member name="M:System.Data.SQLite.SQLiteFunctionEx.GetCollationSequence">
            <summary>
            Obtains the collating sequence in effect for the given function.
            </summary>
            <remarks>
            As an optimization, SQLite does not fill in this information when calling functions, unless the NeedCollationSequence
            boolean value is set to true in the SQLiteFunctionAttribute.
            </remarks>
            <returns></returns>
        </member>
        <member name="T:System.Data.SQLite.FunctionType">
            <summary>
            The type of user-defined function to declare
            </summary>
        </member>
................................................................................
            <summary>
            Helper function for retrieving values from the connectionstring
            </summary>
            <param name="keyword">The keyword to retrieve settings for</param>
            <param name="value">The resulting parameter value</param>
            <returns>Returns true if the value was found and returned</returns>
        </member>






        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.Version">
            <summary>
            Gets/Sets the default version of the SQLite engine to instantiate.  Currently the only valid value is 3, indicating version 3 of the sqlite library.
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.SyncMode">
            <summary>
            Gets/Sets the synchronous mode of the connection string.  Default is "Normal".
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.UseUTF16Encoding">
            <summary>
            Gets/Sets the encoding for the connection string.  The default is "False" which indicates UTF-8 encoding.
            </summary>
        </member>







<
<
<
<
<
<
<
<
<
<
<
<
<
<







 







>
>
>
>
>







 







<
<
<
<







 







>
>
>
>
>
>







|







266
267
268
269
270
271
272














273
274
275
276
277
278
279
...
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
....
1476
1477
1478
1479
1480
1481
1482




1483
1484
1485
1486
1487
1488
1489
....
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
        <member name="M:System.Data.SQLite.SQLiteConnection.CreateFile(System.String)">
            <summary>
            Creates a database file.  This just creates a zero-byte file which SQLite
            will turn into a database when the file is opened properly.
            </summary>
            <param name="databaseFileName">The file to create</param>
        </member>














        <member name="M:System.Data.SQLite.SQLiteConnection.OnStateChange(System.Data.ConnectionState)">
            <summary>
            Raises the state change event when the state of the connection changes
            </summary>
            <param name="newState">The new state.  If it is different from the previous state, an event is raised.</param>
        </member>
        <member name="M:System.Data.SQLite.SQLiteConnection.BeginTransaction(System.Data.IsolationLevel,System.Boolean)">
................................................................................
            Gets/sets the default command timeout for newly-created commands.  This is especially useful for 
            commands used internally such as inside a SQLiteTransaction, where setting the timeout is not possible.
            This can also be set in the ConnectionString with "Default Timeout"
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnection.ServerVersion">
            <summary>
            Returns the version of the underlying SQLite database engine
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnection.SQLiteVersion">
            <summary>
            Returns the version of the underlying SQLite database engine
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnection.State">
            <summary>
            Returns the state of the connection.
            </summary>
................................................................................
            User-defined functions can call the GetCollationSequence() method in this class and use it to compare strings and char arrays.
            </remarks>
        </member>
        <member name="M:System.Data.SQLite.SQLiteFunctionEx.GetCollationSequence">
            <summary>
            Obtains the collating sequence in effect for the given function.
            </summary>




            <returns></returns>
        </member>
        <member name="T:System.Data.SQLite.FunctionType">
            <summary>
            The type of user-defined function to declare
            </summary>
        </member>
................................................................................
            <summary>
            Helper function for retrieving values from the connectionstring
            </summary>
            <param name="keyword">The keyword to retrieve settings for</param>
            <param name="value">The resulting parameter value</param>
            <returns>Returns true if the value was found and returned</returns>
        </member>
        <member name="M:System.Data.SQLite.SQLiteConnectionStringBuilder.FallbackGetProperties(System.Collections.Hashtable)">
            <summary>
            Fallback method for MONO, which doesn't implement DbConnectionStringBuilder.GetProperties()
            </summary>
            <param name="propertyList">The hashtable to fill with property descriptors</param>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.Version">
            <summary>
            Gets/Sets the default version of the SQLite engine to instantiate.  Currently the only valid value is 3, indicating version 3 of the sqlite library.
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.SyncMode">
            <summary>
            Gets/Sets the synchronization mode (file flushing) of the connection string.  Default is "Normal".
            </summary>
        </member>
        <member name="P:System.Data.SQLite.SQLiteConnectionStringBuilder.UseUTF16Encoding">
            <summary>
            Gets/Sets the encoding for the connection string.  The default is "False" which indicates UTF-8 encoding.
            </summary>
        </member>

Changes to bin/System.Data.SQLite.dll.

cannot compute difference between binary files

Changes to bin/System.Data.SQLite.lib.

cannot compute difference between binary files

Changes to bin/itanium/System.Data.SQLite.DLL.

cannot compute difference between binary files

Changes to bin/itanium/System.Data.SQLite.lib.

cannot compute difference between binary files

Changes to bin/test.exe.

cannot compute difference between binary files

Changes to bin/x64/System.Data.SQLite.DLL.

cannot compute difference between binary files

Changes to bin/x64/System.Data.SQLite.lib.

cannot compute difference between binary files

Changes to readme.htm.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
..
20
21
22
23
24
25
26
27
28


29
30
31
32
33
34
35
..
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
...
117
118
119
120
121
122
123

















124
125
126
127
128
129
130
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title></title>
  </head>
  <body>
    ADO.NET 2.0 SQLite Data Provider<br>
    Version 1.0.55.0 August 6, 2008<br>
    Using SQLite 3.6.1<br>
    Written by Robert Simpson (<a href="mailto:robert@blackcastlesoft.com">robert@blackcastlesoft.com</a>)<br>
    Released to the public domain, use at your own risk!<br>
    Official provider website:&nbsp; <a href="http://sqlite.phxsoftware.com">http://sqlite.phxsoftware.com</a><br />
    <br>
    The latest version can be downloaded <a href="http://sourceforge.net/projects/sqlite-dotnet2">
      here</a>
................................................................................
      <b>Features:</b><br>
    </h2>
    <UL>
      <LI>
      Written from scratch on VS2008 specifically for ADO.NET 2.0, implementing all the
      base classes and features recently introduced in the framework, including automatic
      transaction enlistment.<li>Supports the Full
        and Compact .NET Framework, as well as native C/C++ development.&nbsp; 100% binary
        compatible with the original sqlite3.dll.</li>


      <li>Full Entity Framework support (ADO.NET 3.5 SP1)</li>
      <LI>
      On the Compact Framework, it is faster than Sql Server 
      Mobile.  SQLite's installed size is a fraction of Sql Mobile's. It uses less memory at runtime, runs queries faster, and has a smaller database file size as well.
      <li>Encrypted database support.&nbsp; Encrypted databases are fully encrypted and
        support both binary and cleartext password types.</li>
      <LI>
................................................................................
      database to the Servers list, design queries with the Query Designer, 
      drag-and-drop tables onto a Typed DataSet, etc.<LI>
        Full SQLite schema editing inside Visual Studio.&nbsp;
        You can create/edit tables, views, triggers, indexes, check constraints and foreign keys.<LI>
      Single file redistributable.&nbsp; The core sqlite3 codebase and the ADO.NET wrapper 
      are combined into one multi-module assembly.
      <LI>
      Binaries included for Itanium, x64, x86 and ARM processors.
      <LI>
      DbProviderFactory support.
      <LI>
        Full support for ATTACH'ed databases.&nbsp; Exposed as <I>Catalogs</I>
      in the schema.&nbsp; When cloning a connection, all attached databases are 
      automatically re-attached to the new connection.
      <LI>
        DbConnection.GetSchema(...) support includes <I>ReservedWords, MetaDataCollections</I>, <I>DataSourceInformation</I>,
................................................................................
    <p>
      The core sqlite engine is compiled directly from the unmodified source code available
      at the sqlite.org website.&nbsp; Several additional pieces are compiled on top of
      it to extend its functionality, but the core engine's source is not changed.</p>
    <p></p>
    <p>
      <b>Version History</b></p>

















    <p><b>1.0.55.0 - August 6, 2008</b></p>
    <ul>
      <li>Code merge with SQLite 3.6.1</li>
      <li>Added support for the user-contributed extension-functions at
        <a href="http://www.sqlite.org/contrib">http://www.sqlite.org/contrib</a>.&nbsp; 
        Feel free to override any of them with your own implementation.&nbsp; The new 
        functions are: <i>acos, asin, atan, atn2, atan2, acosh, asinh, atanh, 







|







 







|

>
>







 







|
<







 







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
..
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
..
41
42
43
44
45
46
47
48

49
50
51
52
53
54
55
...
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title></title>
  </head>
  <body>
    ADO.NET 2.0 SQLite Data Provider<br>
    Version 1.0.56.0 August 11, 2008<br>
    Using SQLite 3.6.1<br>
    Written by Robert Simpson (<a href="mailto:robert@blackcastlesoft.com">robert@blackcastlesoft.com</a>)<br>
    Released to the public domain, use at your own risk!<br>
    Official provider website:&nbsp; <a href="http://sqlite.phxsoftware.com">http://sqlite.phxsoftware.com</a><br />
    <br>
    The latest version can be downloaded <a href="http://sourceforge.net/projects/sqlite-dotnet2">
      here</a>
................................................................................
      <b>Features:</b><br>
    </h2>
    <UL>
      <LI>
      Written from scratch on VS2008 specifically for ADO.NET 2.0, implementing all the
      base classes and features recently introduced in the framework, including automatic
      transaction enlistment.<li>Supports the Full
        and Compact .NET Framework, and native C/C++ development.&nbsp; 100% binary
        compatible with the original sqlite3.dll.</li>
      <li>Full support for Mono via a &quot;managed only&quot; provider that runs against the 
        official SQLite 3.6.1 or higher library.</li>
      <li>Full Entity Framework support (ADO.NET 3.5 SP1)</li>
      <LI>
      On the Compact Framework, it is faster than Sql Server 
      Mobile.  SQLite's installed size is a fraction of Sql Mobile's. It uses less memory at runtime, runs queries faster, and has a smaller database file size as well.
      <li>Encrypted database support.&nbsp; Encrypted databases are fully encrypted and
        support both binary and cleartext password types.</li>
      <LI>
................................................................................
      database to the Servers list, design queries with the Query Designer, 
      drag-and-drop tables onto a Typed DataSet, etc.<LI>
        Full SQLite schema editing inside Visual Studio.&nbsp;
        You can create/edit tables, views, triggers, indexes, check constraints and foreign keys.<LI>
      Single file redistributable.&nbsp; The core sqlite3 codebase and the ADO.NET wrapper 
      are combined into one multi-module assembly.
      <LI>
              Binaries included for Itanium, x64, x86 and ARM processors.<LI>

      DbProviderFactory support.
      <LI>
        Full support for ATTACH'ed databases.&nbsp; Exposed as <I>Catalogs</I>
      in the schema.&nbsp; When cloning a connection, all attached databases are 
      automatically re-attached to the new connection.
      <LI>
        DbConnection.GetSchema(...) support includes <I>ReservedWords, MetaDataCollections</I>, <I>DataSourceInformation</I>,
................................................................................
    <p>
      The core sqlite engine is compiled directly from the unmodified source code available
      at the sqlite.org website.&nbsp; Several additional pieces are compiled on top of
      it to extend its functionality, but the core engine's source is not changed.</p>
    <p></p>
    <p>
      <b>Version History</b></p>
    <p><b>1.0.56.0 - August 11, 2008</b></p>
    <ul>
      <li>Fixed a bug in the table designer when designing new tables, wherein you had to 
        save the table first before being able to create indexes and foreign keys.</li>
      <li>Tweaks to decimal type handling.&nbsp; The &#39;decimal&#39; type can&#39;t be represented 
        by Int64 or Double (without loss of precision) in SQLite, so we have to fudge it 
        by treating it like a string and converting it back and forth in the provider.&nbsp; 
        Unfortunately backing it to the db as a string causes sorting problems.&nbsp; 
        See <a href="http://sqlite.phxsoftware.com/forums/p/1296/5595.aspx#5595">this 
        post</a> 
        for details on using a custom collation sequence to overcome the sorting issue arising from this patch.</li>
      <li>Minor tweaks and bugfixes to the test program and the provider.</li>
      <li>More adjustments to make the managed-only version of the provider run and pass 
        all tests on Mono.</li>
      <li>LINQ to Entities bits heavily updated and compiled against VS2008 SP1 RTM.&nbsp; SQLite 
        LINQ support is still considered beta.</li>
    </ul>
    <p><b>1.0.55.0 - August 6, 2008</b></p>
    <ul>
      <li>Code merge with SQLite 3.6.1</li>
      <li>Added support for the user-contributed extension-functions at
        <a href="http://www.sqlite.org/contrib">http://www.sqlite.org/contrib</a>.&nbsp; 
        Feel free to override any of them with your own implementation.&nbsp; The new 
        functions are: <i>acos, asin, atan, atn2, atan2, acosh, asinh, atanh, 

Changes to test/TestCases.cs.

56
57
58
59
60
61
62
63


























64
65
66
67
68
69
70
..
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
...
310
311
312
313
314
315
316



317
318
319
320
321
322
323
324



325
326
327
328
329
330
331
332



333
334
335
336
337
338
339
...
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
....
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
....
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111

    internal void CheckSQLite()
    {
      if (_fact.GetType().Name.IndexOf("SQLite", StringComparison.OrdinalIgnoreCase) == -1)
        throw new InconclusiveException("Not a SQLite database");
    }

    [Test(Sequence = 1)]


























    internal void FunctionWithCollation()
    {
      using (DbCommand cmd = _cnn.CreateCommand())
      {
        cmd.CommandText = "SELECT CHARINDEX('pat', 'thepat'), CHARINDEX('pat', 'THEPAT'), CHARINDEX('pat' COLLATE NOCASE, 'THEPAT' COLLATE NOCASE)";
        using (DbDataReader reader = cmd.ExecuteReader())
        {
................................................................................
          reader.Read();
          if (reader.GetInt64(0) != reader.GetInt64(2) || reader.GetInt64(1) != 0 || reader.GetInt64(0) != 4)
            throw new Exception("CharIndex returned wrong results!");
        }
      }
    }

    [Test(Sequence = 2)]
    internal void FunctionWithCollation2()
    {
      using (DbCommand cmd = _cnn.CreateCommand())
      {
        cmd.CommandText = "SELECT CASETEST('pat', 'pat'), CASETEST('pat', 'PAT'), CASETEST('pat' COLLATE NOCASE, 'PAT' COLLATE NOCASE), CASETEST('pat' COLLATE MYSEQUENCE, 'PAT' COLLATE MYSEQUENCE), CASETEST('tap', 'TAP' COLLATE NOCASE)";
        using (DbDataReader reader = cmd.ExecuteReader())
        {
................................................................................
            try
            {
              Field3 = rd.GetDecimal(2);
              throw new Exception("Should have failed type checking!");
            }
            catch (InvalidCastException)
            {



            }
            try
            {
              Field4 = rd.GetDecimal(3);
              throw new Exception("Should have failed type checking!");
            }
            catch (InvalidCastException)
            {



            }
            try
            {
              Field5 = rd.GetDecimal(4);
              throw new Exception("Should have failed type checking!");
            }
            catch (InvalidCastException)
            {



            }
          }
          else throw new Exception("No data in table");
        }
      }
    }

................................................................................

            switch (n)
            {
              case 0:
                if (reader.GetValue(0).GetType() != typeof(long)) throw new Exception("long type non-match");

                if (reader.GetValue(0).Equals((long)1) == false) throw new Exception("long value non-match");
                if (reader.GetValue(1).Equals(new DateTime(1753, 1, 1)) == false) throw new Exception("DateTime value non-match");
                if (reader.GetValue(2).Equals((Decimal)1.05) == false) throw new Exception("Decimal value non-match");

                if (reader.GetInt64(0) != (long)1) throw new Exception("long value non-match");
                if (reader.GetValue(1).Equals(reader.GetDateTime(1)) == false) throw new Exception("DateTime value non-match");
                if (reader.GetValue(2).Equals(reader.GetDecimal(2)) == false) throw new Exception("Decimal value non-match");
                break;
              case 1:
                if (reader.GetValue(0).GetType() != typeof(string)) throw new Exception("String type non-match");
                if (reader.GetValue(0).Equals("One") == false) throw new Exception("String value non-match");
                if (reader.GetValue(1).Equals(new DateTime(2001, 1, 1)) == false) throw new Exception("DateTime value non-match");
                if (reader.GetValue(2).Equals((Decimal)1.0) == false) throw new Exception("Decimal value non-match");

                if (reader.GetString(0) != "One") throw new Exception("String value non-match");
                if (reader.GetValue(1).Equals(reader.GetDateTime(1)) == false) throw new Exception("DateTime value non-match");
                if (reader.GetValue(2).Equals(reader.GetDecimal(2)) == false) throw new Exception("Decimal value non-match");
                break;
              case 2:
                if (reader.GetValue(0).GetType() != typeof(double)) throw new Exception("Double type non-match");
                if (reader.GetValue(0).Equals(1.01) == false) throw new Exception("Double value non-match");
                if (reader.GetValue(1).Equals(now) == false) throw new Exception("DateTime value non-match");
                if (reader.GetValue(2).Equals((Decimal)9.91) == false) throw new Exception("Decimal value non-match");

                if (reader.GetDouble(0) != 1.01) throw new Exception("Double value non-match");
                if (reader.GetValue(1).Equals(reader.GetDateTime(1)) == false) throw new Exception("DateTime value non-match");
                if (reader.GetValue(2).Equals(reader.GetDecimal(2)) == false) throw new Exception("Decimal value non-match");
                break;
            }
          }
        }
      }
    }

................................................................................
              }
              catch (Exception e)
              {
                if (e is ArgumentException) throw new Exception(e.Message);

                cmdEnd = Environment.TickCount;
                if (cmdEnd - cmdStart < 2000 || cmdEnd - cmdStart > 3000)
                  throw new Exception("Gave up the lock too soon!"); // Didn't wait the right amount of time

              }
            }
          }
        }
      }
    }
................................................................................
        test.cnn.Open();

      int start = Environment.TickCount;
      try
      {
        using (DbCommand cmd = test.cnn.CreateCommand())
        {
          while (Environment.TickCount - start < 5000)
          {
            using (DbTransaction trans = test.cnn.BeginTransaction())
            {
              cmd.CommandText = String.Format("SELECT * FROM MultiThreadedTest WHERE ThreadId = {0}", test.t.ManagedThreadId);
              using (DbDataReader reader = cmd.ExecuteReader())
              {
                while (reader.Read())







|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







 







|







 







>
>
>








>
>
>








>
>
>







 







|


|
|
|




|



|
|




|



|
|







 







|







 







|







56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
..
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
...
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
...
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
....
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
....
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146

    internal void CheckSQLite()
    {
      if (_fact.GetType().Name.IndexOf("SQLite", StringComparison.OrdinalIgnoreCase) == -1)
        throw new InconclusiveException("Not a SQLite database");
    }

    //[Test(Sequence = 1)]
    internal void ParseTest()
    {
      using (DbCommand cmd = _cnn.CreateCommand())
      {
        cmd.CommandText = @"
CREATE TEMP TABLE A(ID INTEGER, BID INTEGER);CREATE TEMP TABLE B(ID INTEGER, MYVAL VARCHAR);
INSERT INTO A (ID, BID) VALUES(2, 1);
INSERT INTO B (ID, MYVAL) VALUES(1,'TEST');
";
        cmd.ExecuteNonQuery();
        
        cmd.CommandText = "select *, (select 1 as c from b where b.id = a.bid) from a;";
        using (DbDataReader reader = cmd.ExecuteReader())
        {
          reader.Read();
        }

        cmd.CommandText = "select *, (select count(c) from (select 1 as c from b where b.id = a.bid)) from a;";
        using (DbDataReader reader = cmd.ExecuteReader())
        {
          reader.Read();
        }
      }
    }

    [Test(Sequence = 8)]
    internal void FunctionWithCollation()
    {
      using (DbCommand cmd = _cnn.CreateCommand())
      {
        cmd.CommandText = "SELECT CHARINDEX('pat', 'thepat'), CHARINDEX('pat', 'THEPAT'), CHARINDEX('pat' COLLATE NOCASE, 'THEPAT' COLLATE NOCASE)";
        using (DbDataReader reader = cmd.ExecuteReader())
        {
................................................................................
          reader.Read();
          if (reader.GetInt64(0) != reader.GetInt64(2) || reader.GetInt64(1) != 0 || reader.GetInt64(0) != 4)
            throw new Exception("CharIndex returned wrong results!");
        }
      }
    }

    [Test(Sequence = 9)]
    internal void FunctionWithCollation2()
    {
      using (DbCommand cmd = _cnn.CreateCommand())
      {
        cmd.CommandText = "SELECT CASETEST('pat', 'pat'), CASETEST('pat', 'PAT'), CASETEST('pat' COLLATE NOCASE, 'PAT' COLLATE NOCASE), CASETEST('pat' COLLATE MYSEQUENCE, 'PAT' COLLATE MYSEQUENCE), CASETEST('tap', 'TAP' COLLATE NOCASE)";
        using (DbDataReader reader = cmd.ExecuteReader())
        {
................................................................................
            try
            {
              Field3 = rd.GetDecimal(2);
              throw new Exception("Should have failed type checking!");
            }
            catch (InvalidCastException)
            {
            }
            catch (FormatException)
            {
            }
            try
            {
              Field4 = rd.GetDecimal(3);
              throw new Exception("Should have failed type checking!");
            }
            catch (InvalidCastException)
            {
            }
            catch (FormatException)
            {
            }
            try
            {
              Field5 = rd.GetDecimal(4);
              throw new Exception("Should have failed type checking!");
            }
            catch (InvalidCastException)
            {
            }
            catch (FormatException)
            {
            }
          }
          else throw new Exception("No data in table");
        }
      }
    }

................................................................................

            switch (n)
            {
              case 0:
                if (reader.GetValue(0).GetType() != typeof(long)) throw new Exception("long type non-match");

                if (reader.GetValue(0).Equals((long)1) == false) throw new Exception("long value non-match");
                if (reader.GetValue(1).Equals(new DateTime(1753, 1, 1)) == false) throw new Exception(String.Format("DateTime value non-match expected {0} got {1}", new DateTime(1753, 1, 1), reader.GetValue(1)));
                if (reader.GetValue(2).Equals((Decimal)1.05) == false) throw new Exception("Decimal value non-match");

                if (reader.GetValue(0).Equals(reader.GetInt64(0)) == false) throw new Exception(String.Format("long value failed to match itself, {0} and {1}", reader.GetValue(0), reader.GetInt64(0)));
                if (reader.GetValue(1).Equals(reader.GetDateTime(1)) == false) throw new Exception(String.Format("DateTime failed to match itself {0} and {1}", reader.GetValue(1), reader.GetDateTime(1)));
                if (reader.GetValue(2).Equals(reader.GetDecimal(2)) == false) throw new Exception(String.Format("Decimal failed to match itself {0} and {1}", reader.GetValue(2), reader.GetDecimal(2)));
                break;
              case 1:
                if (reader.GetValue(0).GetType() != typeof(string)) throw new Exception("String type non-match");
                if (reader.GetValue(0).Equals("One") == false) throw new Exception("String value non-match");
                if (reader.GetValue(1).Equals(new DateTime(2001, 1, 1)) == false) throw new Exception(String.Format("DateTime value non-match expected {0} got {1}", new DateTime(2001, 1, 1), reader.GetValue(1)));
                if (reader.GetValue(2).Equals((Decimal)1.0) == false) throw new Exception("Decimal value non-match");

                if (reader.GetString(0) != "One") throw new Exception("String value non-match");
                if (reader.GetValue(1).Equals(reader.GetDateTime(1)) == false) throw new Exception(String.Format("DateTime failed to match itself {0} and {1}", reader.GetValue(1), reader.GetDateTime(1)));
                if (reader.GetValue(2).Equals(reader.GetDecimal(2)) == false) throw new Exception(String.Format("Decimal failed to match itself {0} and {1}", reader.GetValue(2), reader.GetDecimal(2)));
                break;
              case 2:
                if (reader.GetValue(0).GetType() != typeof(double)) throw new Exception("Double type non-match");
                if (reader.GetValue(0).Equals(1.01) == false) throw new Exception("Double value non-match");
                if (reader.GetValue(1).Equals(now) == false) throw new Exception(String.Format("DateTime value non-match, expected {0} got {1}", now, reader.GetValue(1)));
                if (reader.GetValue(2).Equals((Decimal)9.91) == false) throw new Exception("Decimal value non-match");

                if (reader.GetDouble(0) != 1.01) throw new Exception("Double value non-match");
                if (reader.GetValue(1).Equals(reader.GetDateTime(1)) == false) throw new Exception(String.Format("DateTime failed to match itself {0} and {1}", reader.GetValue(1), reader.GetDateTime(1)));
                if (reader.GetValue(2).Equals(reader.GetDecimal(2)) == false) throw new Exception(String.Format("Decimal failed to match itself {0} and {1}", reader.GetValue(2), reader.GetDecimal(2)));
                break;
            }
          }
        }
      }
    }

................................................................................
              }
              catch (Exception e)
              {
                if (e is ArgumentException) throw new Exception(e.Message);

                cmdEnd = Environment.TickCount;
                if (cmdEnd - cmdStart < 2000 || cmdEnd - cmdStart > 3000)
                  throw new Exception("Did not give up the lock at the right time!"); // Didn't wait the right amount of time

              }
            }
          }
        }
      }
    }
................................................................................
        test.cnn.Open();

      int start = Environment.TickCount;
      try
      {
        using (DbCommand cmd = test.cnn.CreateCommand())
        {
          while (Environment.TickCount - start < 2000)
          {
            using (DbTransaction trans = test.cnn.BeginTransaction())
            {
              cmd.CommandText = String.Format("SELECT * FROM MultiThreadedTest WHERE ThreadId = {0}", test.t.ManagedThreadId);
              using (DbDataReader reader = cmd.ExecuteReader())
              {
                while (reader.Read())

Changes to test/TestCasesDialog.cs.

72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
        {
          _grid.Rows[_grid.Rows.Count - 1].Cells[1].Style.BackColor = Color.Red;
        }
        else if (args.Result == TestResultEnum.Inconclusive)
        {
          _grid.Rows[_grid.Rows.Count - 1].Cells[1].Style.BackColor = Color.LightBlue;
        }
        _grid.Rows[_grid.Rows.Count - 1].Height = _grid.Rows[_grid.Rows.Count - 1].GetPreferredHeight(_grid.Rows.Count - 1, DataGridViewAutoSizeRowMode.AllCells, true);
      }
    }

    void _test_OnTestStarting(object sender, TestEventArgs args)
    {
      if (InvokeRequired)
        Invoke(new TestStartingEvent(_test_OnTestStarting), sender, args);







|







72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
        {
          _grid.Rows[_grid.Rows.Count - 1].Cells[1].Style.BackColor = Color.Red;
        }
        else if (args.Result == TestResultEnum.Inconclusive)
        {
          _grid.Rows[_grid.Rows.Count - 1].Cells[1].Style.BackColor = Color.LightBlue;
        }
        //_grid.Rows[_grid.Rows.Count - 1].Height = _grid.Rows[_grid.Rows.Count - 1].GetPreferredHeight(_grid.Rows.Count - 1, DataGridViewAutoSizeRowMode.AllCells, true);
      }
    }

    void _test_OnTestStarting(object sender, TestEventArgs args)
    {
      if (InvokeRequired)
        Invoke(new TestStartingEvent(_test_OnTestStarting), sender, args);

Changes to testlinq/App.Config.

1
2
3
4
5
6
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <connectionStrings>
    <add name="northwindEntities" connectionString="metadata=res://*/NorthwindModel.csdl|res://*/NorthwindModel.ssdl|res://*/NorthwindModel.msl;provider=System.Data.SQLite;provider connection string=&quot;data source=c:\src\northwind.db&quot;" providerName="System.Data.EntityClient" />
  </connectionStrings>
</configuration>



|


1
2
3
4
5
6
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <connectionStrings>
    <add name="northwindEntities" connectionString="metadata=res://*/NorthwindModel.csdl|res://*/NorthwindModel.ssdl|res://*/NorthwindModel.msl;provider=System.Data.SQLite;provider connection string=&quot;data source=c:\src\sqlite.net\testlinq\northwind.db&quot;" providerName="System.Data.EntityClient" />
  </connectionStrings>
</configuration>

Changes to testlinq/NorthwindModel.Designer.cs.

1
2
3
4
5
6
7
8
9
10
11
..
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:2.0.50727.3051
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

[assembly: global::System.Data.Objects.DataClasses.EdmSchemaAttribute()]
................................................................................
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "FK_Orders_ShipVia_ShipperID", "Shippers", global::System.Data.Metadata.Edm.RelationshipMultiplicity.ZeroOrOne, typeof(testlinq.Shippers), "Orders", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Orders))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "FK_Products_SupplierID_SupplierID", "Suppliers", global::System.Data.Metadata.Edm.RelationshipMultiplicity.ZeroOrOne, typeof(testlinq.Suppliers), "Products", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Products))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "FK_Territories_RegionID_RegionID", "Region", global::System.Data.Metadata.Edm.RelationshipMultiplicity.One, typeof(testlinq.Region), "Territories", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Territories))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "CustomerCustomerDemo", "Customers", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Customers), "CustomerDemographics", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.CustomerDemographics))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "EmployeeTerritories", "Employees", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Employees), "Territories", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Territories))]

// Original file name:
// Generation date: 8/3/2008 3:16:52 AM
namespace testlinq
{
    
    /// <summary>
    /// There are no comments for northwindEntities in the schema.
    /// </summary>
    public partial class northwindEntities : global::System.Data.Objects.ObjectContext



|







 







|







1
2
3
4
5
6
7
8
9
10
11
..
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:2.0.50727.3053
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

[assembly: global::System.Data.Objects.DataClasses.EdmSchemaAttribute()]
................................................................................
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "FK_Orders_ShipVia_ShipperID", "Shippers", global::System.Data.Metadata.Edm.RelationshipMultiplicity.ZeroOrOne, typeof(testlinq.Shippers), "Orders", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Orders))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "FK_Products_SupplierID_SupplierID", "Suppliers", global::System.Data.Metadata.Edm.RelationshipMultiplicity.ZeroOrOne, typeof(testlinq.Suppliers), "Products", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Products))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "FK_Territories_RegionID_RegionID", "Region", global::System.Data.Metadata.Edm.RelationshipMultiplicity.One, typeof(testlinq.Region), "Territories", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Territories))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "CustomerCustomerDemo", "Customers", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Customers), "CustomerDemographics", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.CustomerDemographics))]
[assembly: global::System.Data.Objects.DataClasses.EdmRelationshipAttribute("northwindModel", "EmployeeTerritories", "Employees", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Employees), "Territories", global::System.Data.Metadata.Edm.RelationshipMultiplicity.Many, typeof(testlinq.Territories))]

// Original file name:
// Generation date: 8/11/2008 1:35:38 PM
namespace testlinq
{
    
    /// <summary>
    /// There are no comments for northwindEntities in the schema.
    /// </summary>
    public partial class northwindEntities : global::System.Data.Objects.ObjectContext

Changes to testlinq/NorthwindModel.edmx.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
..
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
...
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
...
380
381
382
383
384
385
386

387
388
389
390
391
392
393
394
<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx Version="1.0" xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx">
  <!-- EF Runtime content -->
  <edmx:Runtime>
    <!-- SSDL content -->
    <edmx:StorageModels>
    <Schema Namespace="northwindModel.Store" Alias="Self" Provider="System.Data.SQLite" ProviderManifestToken="ISO8601" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns="http://schemas.microsoft.com/ado/2006/04/edm/ssdl">
        <EntityContainer Name="northwindModelStoreContainer">
          <EntitySet Name="Categories" EntityType="northwindModel.Store.Categories" store:Type="Tables" />
          <EntitySet Name="CustomerCustomerDemo" EntityType="northwindModel.Store.CustomerCustomerDemo" store:Type="Tables" />
          <EntitySet Name="CustomerDemographics" EntityType="northwindModel.Store.CustomerDemographics" store:Type="Tables" />
          <EntitySet Name="Customers" EntityType="northwindModel.Store.Customers" store:Type="Tables" />
          <EntitySet Name="Employees" EntityType="northwindModel.Store.Employees" store:Type="Tables" />
          <EntitySet Name="EmployeeTerritories" EntityType="northwindModel.Store.EmployeeTerritories" store:Type="Tables" />
................................................................................
          <EntitySet Name="Shippers" EntityType="northwindModel.Store.Shippers" store:Type="Tables" />
          <EntitySet Name="Suppliers" EntityType="northwindModel.Store.Suppliers" store:Type="Tables" />
          <EntitySet Name="Territories" EntityType="northwindModel.Store.Territories" store:Type="Tables" />
          <AssociationSet Name="FK_CustomerCustomerDemo_CustomerID_CustomerID" Association="northwindModel.Store.FK_CustomerCustomerDemo_CustomerID_CustomerID">
            <End Role="Customers" EntitySet="Customers" />
            <End Role="CustomerCustomerDemo" EntitySet="CustomerCustomerDemo" />
          </AssociationSet>
          <AssociationSet Name="FK_CustomerCustomerDemo_CustomerTypeID_CustomerTypeId" Association="northwindModel.Store.FK_CustomerCustomerDemo_CustomerTypeID_CustomerTypeId">
            <End Role="CustomerDemographics" EntitySet="CustomerDemographics" />
            <End Role="CustomerCustomerDemo" EntitySet="CustomerCustomerDemo" />
          </AssociationSet>
          <AssociationSet Name="FK_Employees_ReportsTo_EmployeeID" Association="northwindModel.Store.FK_Employees_ReportsTo_EmployeeID">
            <End Role="Employees" EntitySet="Employees" />
            <End Role="Employees1" EntitySet="Employees" />
          </AssociationSet>
................................................................................
              <PropertyRef Name="CustomerID" />
            </Principal>
            <Dependent Role="CustomerCustomerDemo">
              <PropertyRef Name="CustomerID" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CustomerCustomerDemo_CustomerTypeID_CustomerTypeId">
          <End Role="CustomerDemographics" Type="northwindModel.Store.CustomerDemographics" Multiplicity="1" />
          <End Role="CustomerCustomerDemo" Type="northwindModel.Store.CustomerCustomerDemo" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="CustomerDemographics">
              <PropertyRef Name="CustomerTypeID" />
            </Principal>
            <Dependent Role="CustomerCustomerDemo">
................................................................................
              <PropertyRef Name="RegionID" />
            </Principal>
            <Dependent Role="Territories">
              <PropertyRef Name="RegionID" />
            </Dependent>
          </ReferentialConstraint>
        </Association>

      </Schema></edmx:StorageModels>
    <!-- CSDL content -->
    <edmx:ConceptualModels>
      <Schema Namespace="northwindModel" Alias="Self" xmlns="http://schemas.microsoft.com/ado/2006/04/edm">
        <EntityContainer Name="northwindEntities">
          <EntitySet Name="Categories" EntityType="northwindModel.Categories" />
          <EntitySet Name="CustomerDemographics" EntityType="northwindModel.CustomerDemographics" />
          <EntitySet Name="Customers" EntityType="northwindModel.Customers" />






|







 







|







 







|







 







>
|







1
2
3
4
5
6
7
8
9
10
11
12
13
14
..
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
...
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
...
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx Version="1.0" xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx">
  <!-- EF Runtime content -->
  <edmx:Runtime>
    <!-- SSDL content -->
    <edmx:StorageModels>
      <Schema Namespace="northwindModel.Store" Alias="Self" Provider="System.Data.SQLite" ProviderManifestToken="ISO8601" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns="http://schemas.microsoft.com/ado/2006/04/edm/ssdl">
        <EntityContainer Name="northwindModelStoreContainer">
          <EntitySet Name="Categories" EntityType="northwindModel.Store.Categories" store:Type="Tables" />
          <EntitySet Name="CustomerCustomerDemo" EntityType="northwindModel.Store.CustomerCustomerDemo" store:Type="Tables" />
          <EntitySet Name="CustomerDemographics" EntityType="northwindModel.Store.CustomerDemographics" store:Type="Tables" />
          <EntitySet Name="Customers" EntityType="northwindModel.Store.Customers" store:Type="Tables" />
          <EntitySet Name="Employees" EntityType="northwindModel.Store.Employees" store:Type="Tables" />
          <EntitySet Name="EmployeeTerritories" EntityType="northwindModel.Store.EmployeeTerritories" store:Type="Tables" />
................................................................................
          <EntitySet Name="Shippers" EntityType="northwindModel.Store.Shippers" store:Type="Tables" />
          <EntitySet Name="Suppliers" EntityType="northwindModel.Store.Suppliers" store:Type="Tables" />
          <EntitySet Name="Territories" EntityType="northwindModel.Store.Territories" store:Type="Tables" />
          <AssociationSet Name="FK_CustomerCustomerDemo_CustomerID_CustomerID" Association="northwindModel.Store.FK_CustomerCustomerDemo_CustomerID_CustomerID">
            <End Role="Customers" EntitySet="Customers" />
            <End Role="CustomerCustomerDemo" EntitySet="CustomerCustomerDemo" />
          </AssociationSet>
          <AssociationSet Name="FK_CustomerCustomerDemo_CustomerTypeID_CustomerTypeID" Association="northwindModel.Store.FK_CustomerCustomerDemo_CustomerTypeID_CustomerTypeID">
            <End Role="CustomerDemographics" EntitySet="CustomerDemographics" />
            <End Role="CustomerCustomerDemo" EntitySet="CustomerCustomerDemo" />
          </AssociationSet>
          <AssociationSet Name="FK_Employees_ReportsTo_EmployeeID" Association="northwindModel.Store.FK_Employees_ReportsTo_EmployeeID">
            <End Role="Employees" EntitySet="Employees" />
            <End Role="Employees1" EntitySet="Employees" />
          </AssociationSet>
................................................................................
              <PropertyRef Name="CustomerID" />
            </Principal>
            <Dependent Role="CustomerCustomerDemo">
              <PropertyRef Name="CustomerID" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CustomerCustomerDemo_CustomerTypeID_CustomerTypeID">
          <End Role="CustomerDemographics" Type="northwindModel.Store.CustomerDemographics" Multiplicity="1" />
          <End Role="CustomerCustomerDemo" Type="northwindModel.Store.CustomerCustomerDemo" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="CustomerDemographics">
              <PropertyRef Name="CustomerTypeID" />
            </Principal>
            <Dependent Role="CustomerCustomerDemo">
................................................................................
              <PropertyRef Name="RegionID" />
            </Principal>
            <Dependent Role="Territories">
              <PropertyRef Name="RegionID" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
      </Schema>
    </edmx:StorageModels>
    <!-- CSDL content -->
    <edmx:ConceptualModels>
      <Schema Namespace="northwindModel" Alias="Self" xmlns="http://schemas.microsoft.com/ado/2006/04/edm">
        <EntityContainer Name="northwindEntities">
          <EntitySet Name="Categories" EntityType="northwindModel.Categories" />
          <EntitySet Name="CustomerDemographics" EntityType="northwindModel.CustomerDemographics" />
          <EntitySet Name="Customers" EntityType="northwindModel.Customers" />

Changes to testlinq/Program.cs.

99
100
101
102
103
104
105
106
107
108
109
110
111
112
113

          foreach (Orders o in query)
          {
            Console.WriteLine(o.ShipPostalCode);
          }
        }

        // This query fails due to a SQLite core issue.  Currently pending review by Dr. Hipp
        //{
        //  var query = from p in db.Products
        //              where p.Order_Details.Count(od => od.Orders.Customers.Country == p.Suppliers.Country) > 2
        //              select p;

        //  foreach (Products p in query)
        //  {







|







99
100
101
102
103
104
105
106
107
108
109
110
111
112
113

          foreach (Orders o in query)
          {
            Console.WriteLine(o.ShipPostalCode);
          }
        }

         //This query fails due to a SQLite core issue.  Currently pending review by Dr. Hipp
        //{
        //  var query = from p in db.Products
        //              where p.Order_Details.Count(od => od.Orders.Customers.Country == p.Suppliers.Country) > 2
        //              select p;

        //  foreach (Products p in query)
        //  {

Changes to testlinq/northwind.db.

cannot compute difference between binary files

Changes to testlinq/testlinq.csproj.

1
2
3
4
5
6
7
8
9
10
11
12
13
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>9.0.30703</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{9D3CF7A6-092A-4B05-B0E4-BEF6944525B3}</ProjectGuid>
    <OutputType>Exe</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>testlinq</RootNamespace>
    <AssemblyName>testlinq</AssemblyName>
    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>





|







1
2
3
4
5
6
7
8
9
10
11
12
13
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup>
    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>9.0.30729</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{9D3CF7A6-092A-4B05-B0E4-BEF6944525B3}</ProjectGuid>
    <OutputType>Exe</OutputType>
    <AppDesignerFolder>Properties</AppDesignerFolder>
    <RootNamespace>testlinq</RootNamespace>
    <AssemblyName>testlinq</AssemblyName>
    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>

Changes to testlinq/testlinq.csproj.user.

1
2
3
4
5
6
7

8
9
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <StartWorkingDirectory>
    </StartWorkingDirectory>

  </PropertyGroup>
</Project>







>


1
2
3
4
5
6
7
8
9
10
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
    <EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
  </PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <StartWorkingDirectory>
    </StartWorkingDirectory>
    <EnableUnmanagedDebugging>true</EnableUnmanagedDebugging>
  </PropertyGroup>
</Project>

Changes to tools/install/Resources/System.Data.SQLite.dll.

cannot compute difference between binary files

Changes to tools/setup/exe/setup/setup.rc.

53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
..
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85

/////////////////////////////////////////////////////////////////////////////
//
// Version
//

VS_VERSION_INFO VERSIONINFO
 FILEVERSION 1,0,55,0
 PRODUCTVERSION 1,0,0,0
 FILEFLAGSMASK 0x17L
#ifdef _DEBUG
 FILEFLAGS 0x1L
#else
 FILEFLAGS 0x0L
#endif
................................................................................
BEGIN
    BLOCK "StringFileInfo"
    BEGIN
        BLOCK "040904b0"
        BEGIN
            VALUE "Comments", "http://sqlite.phxsoftware.com"
            VALUE "FileDescription", "SQLite ADO.NET 2.0 Setup"
            VALUE "FileVersion", "1.0.55.0"
            VALUE "InternalName", "setup"
            VALUE "LegalCopyright", "Released to the public domain"
            VALUE "OriginalFilename", "setup.exe"
            VALUE "ProductName", "System.Data.SQLite"
            VALUE "ProductVersion", "1.0"
        END
    END







|







 







|







53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
..
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85

/////////////////////////////////////////////////////////////////////////////
//
// Version
//

VS_VERSION_INFO VERSIONINFO
 FILEVERSION 1,0,56,0
 PRODUCTVERSION 1,0,0,0
 FILEFLAGSMASK 0x17L
#ifdef _DEBUG
 FILEFLAGS 0x1L
#else
 FILEFLAGS 0x0L
#endif
................................................................................
BEGIN
    BLOCK "StringFileInfo"
    BEGIN
        BLOCK "040904b0"
        BEGIN
            VALUE "Comments", "http://sqlite.phxsoftware.com"
            VALUE "FileDescription", "SQLite ADO.NET 2.0 Setup"
            VALUE "FileVersion", "1.0.56.0"
            VALUE "InternalName", "setup"
            VALUE "LegalCopyright", "Released to the public domain"
            VALUE "OriginalFilename", "setup.exe"
            VALUE "ProductName", "System.Data.SQLite"
            VALUE "ProductVersion", "1.0"
        END
    END

Changes to tools/setup/sqlite_setup.suo.

cannot compute difference between binary files

Changes to tools/setup/sqlite_setup.vdproj.

630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
...
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
...
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
...
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
...
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
....
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
....
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_29B62FDE3E56411381A6E8B358CBB0F5"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:System.Data.SQLite.Linq, Version=2.0.35.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL"
                "ScatterAssemblies"
                {
                    "_29B62FDE3E56411381A6E8B358CBB0F5"
                    {
                    "Name" = "8:System.Data.SQLite.Linq.dll"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_2C7EDFF06B61482393D94E3A63D90113"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:test, Version=1.0.0.25019, Culture=neutral, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_2C7EDFF06B61482393D94E3A63D90113"
                    {
                    "Name" = "8:test.exe"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:TRUE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_40DFF08BA903482D807E715A041CA8B1"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:install, Version=1.0.0.18790, Culture=neutral, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_40DFF08BA903482D807E715A041CA8B1"
                    {
                    "Name" = "8:install.exe"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_40F352185F3B41A485F42BFC64BF9162"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:testce, Version=1.0.0.18356, Culture=neutral, processorArchitecture=MSIL"
                "ScatterAssemblies"
                {
                    "_40F352185F3B41A485F42BFC64BF9162"
                    {
                    "Name" = "8:testce.exe"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_A18DBDB7776215EAD9A52C96F8CA1E91"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:System.Data.SQLite, Version=1.0.55.0, Culture=neutral, PublicKeyToken=1fdb50b1b62b4c84, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_A18DBDB7776215EAD9A52C96F8CA1E91"
                    {
                    "Name" = "8:System.Data.SQLite.DLL"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:TRUE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_F320FBAE871DA320178BEEA242900CC7"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:System.Data.SQLite, Version=1.0.55.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_F320FBAE871DA320178BEEA242900CC7"
                    {
                    "Name" = "8:System.Data.SQLite.DLL"
                    "Attributes" = "3:512"
                    }
................................................................................
        "LangId" = "3:1033"
        "RequiresElevation" = "11:FALSE"
        }
        "Product"
        {
        "Name" = "8:Microsoft Visual Studio"
        "ProductName" = "8:SQLite ADO.NET 2.0 Provider"
        "ProductCode" = "8:{F223E3D2-98AC-4558-B660-D51BFF47C274}"
        "PackageCode" = "8:{3A3FFC71-54CB-472C-88A8-1E430A710E46}"
        "UpgradeCode" = "8:{78329A82-AFB1-453B-AF00-D46AC911DA89}"
        "RestartWWWService" = "11:FALSE"
        "RemovePreviousVersions" = "11:TRUE"
        "DetectNewerInstalledVersion" = "11:TRUE"
        "InstallAllUsers" = "11:TRUE"
        "ProductVersion" = "8:1.055.0"
        "Manufacturer" = "8:Phoenix Software Solutions, LLC"
        "ARPHELPTELEPHONE" = "8:"
        "ARPHELPLINK" = "8:http://sqlite.phxsoftware.com"
        "Title" = "8:SQLite ADO.NET 2.0 Provider"
        "Subject" = "8:"
        "ARPCONTACT" = "8:Phoenix Software Solutions, LLC"
        "Keywords" = "8:"







|







 







|







 







|







 







|







 







|







 







|







 







|
|





|







630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
...
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
...
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
...
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
...
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
....
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
....
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_29B62FDE3E56411381A6E8B358CBB0F5"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:System.Data.SQLite.Linq, Version=2.0.36.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL"
                "ScatterAssemblies"
                {
                    "_29B62FDE3E56411381A6E8B358CBB0F5"
                    {
                    "Name" = "8:System.Data.SQLite.Linq.dll"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_2C7EDFF06B61482393D94E3A63D90113"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:test, Version=1.0.0.21862, Culture=neutral, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_2C7EDFF06B61482393D94E3A63D90113"
                    {
                    "Name" = "8:test.exe"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:TRUE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_40DFF08BA903482D807E715A041CA8B1"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:install, Version=1.0.0.21008, Culture=neutral, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_40DFF08BA903482D807E715A041CA8B1"
                    {
                    "Name" = "8:install.exe"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_40F352185F3B41A485F42BFC64BF9162"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:testce, Version=1.0.0.21647, Culture=neutral, processorArchitecture=MSIL"
                "ScatterAssemblies"
                {
                    "_40F352185F3B41A485F42BFC64BF9162"
                    {
                    "Name" = "8:testce.exe"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:FALSE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_A18DBDB7776215EAD9A52C96F8CA1E91"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:System.Data.SQLite, Version=1.0.56.0, Culture=neutral, PublicKeyToken=1fdb50b1b62b4c84, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_A18DBDB7776215EAD9A52C96F8CA1E91"
                    {
                    "Name" = "8:System.Data.SQLite.DLL"
                    "Attributes" = "3:512"
                    }
................................................................................
            "IsDependency" = "11:TRUE"
            "IsolateTo" = "8:"
            }
            "{9F6F8455-1EF1-4B85-886A-4223BCC8E7F7}:_F320FBAE871DA320178BEEA242900CC7"
            {
            "AssemblyRegister" = "3:1"
            "AssemblyIsInGAC" = "11:FALSE"
            "AssemblyAsmDisplayName" = "8:System.Data.SQLite, Version=1.0.56.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=x86"
                "ScatterAssemblies"
                {
                    "_F320FBAE871DA320178BEEA242900CC7"
                    {
                    "Name" = "8:System.Data.SQLite.DLL"
                    "Attributes" = "3:512"
                    }
................................................................................
        "LangId" = "3:1033"
        "RequiresElevation" = "11:FALSE"
        }
        "Product"
        {
        "Name" = "8:Microsoft Visual Studio"
        "ProductName" = "8:SQLite ADO.NET 2.0 Provider"
        "ProductCode" = "8:{414A1727-0EEC-4F19-BA00-79CCD8EB2E8A}"
        "PackageCode" = "8:{D61282A9-3BE9-4C9A-A44D-DF9A6F4B89AB}"
        "UpgradeCode" = "8:{78329A82-AFB1-453B-AF00-D46AC911DA89}"
        "RestartWWWService" = "11:FALSE"
        "RemovePreviousVersions" = "11:TRUE"
        "DetectNewerInstalledVersion" = "11:TRUE"
        "InstallAllUsers" = "11:TRUE"
        "ProductVersion" = "8:1.056.0"
        "Manufacturer" = "8:Phoenix Software Solutions, LLC"
        "ARPHELPTELEPHONE" = "8:"
        "ARPHELPLINK" = "8:http://sqlite.phxsoftware.com"
        "Title" = "8:SQLite ADO.NET 2.0 Provider"
        "Subject" = "8:"
        "ARPCONTACT" = "8:Phoenix Software Solutions, LLC"
        "Keywords" = "8:"