[sqlite] System.Data.SQLite Reserved Words Bug

2011-07-09 Thread Patrick Earl
First I wanted to say that I was so excited to see the 1.0.74 release
with .NET 4, zip files, and SQLite 3.7.7.  I've been waiting for .NET
4 support for a long while.  Thanks so much. :)

Unfortunately, I was unable to upgrade from 1.0.66 because of the
following problem.

Using this code produces the following exception:

using System;
using System.Collections.Generic;
using System.Data.SQLite;
using System.Linq;
using System.Text;

namespace ConsoleApplication4
{
class Program
{
static void Main(string[] args)
{
SQLiteConnection conn = new SQLiteConnection(Data Source=test.db);
conn.Open();
conn.GetSchema(ReservedWords);
}
}
}

/*
System.Resources.MissingManifestResourceException was unhandled
  Message=Could not find any resources appropriate for the specified
culture or the neutral culture.  Make sure
System.Data.SQLite.SR.resources was correctly embedded or linked
into assembly System.Data.SQLite at compile time, or that all the
satellite assemblies required are loadable and fully signed.
  Source=mscorlib
  StackTrace:
   at 
System.Resources.ManifestBasedResourceGroveler.HandleResourceStreamMissing(String
fileName)
   at 
System.Resources.ManifestBasedResourceGroveler.GrovelForResourceSet(CultureInfo
culture, Dictionary`2 localResourceSets, Boolean tryParents, Boolean
createIfNotExists, StackCrawlMark stackMark)
   at System.Resources.ResourceManager.InternalGetResourceSet(CultureInfo
requestedCulture, Boolean createIfNotExists, Boolean tryParents,
StackCrawlMark stackMark)
   at System.Resources.ResourceManager.InternalGetResourceSet(CultureInfo
culture, Boolean createIfNotExists, Boolean tryParents)
   at System.Resources.ResourceManager.GetString(String name,
CultureInfo culture)
   at System.Data.SQLite.SR.get_Keywords() in
c:\dev\sqlite\dotnet\System.Data.SQLite\SR.Designer.cs:line 87
   at System.Data.SQLite.SQLiteConnection.Schema_ReservedWords()
in c:\dev\sqlite\dotnet\System.Data.SQLite\SQLiteConnection.cs:line
1239
   at System.Data.SQLite.SQLiteConnection.GetSchema(String
collectionName, String[] restrictionValues) in
c:\dev\sqlite\dotnet\System.Data.SQLite\SQLiteConnection.cs:line 1223
   at System.Data.SQLite.SQLiteConnection.GetSchema(String
collectionName) in
c:\dev\sqlite\dotnet\System.Data.SQLite\SQLiteConnection.cs:line 1176
   at ConsoleApplication4.Program.Main(String[] args) in
c:\temp\projects\ConsoleApplication4\Program.cs:line 15
   at System.AppDomain._nExecuteAssembly(RuntimeAssembly assembly,
String[] args)
   at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
   at System.Threading.ExecutionContext.Run(ExecutionContext
executionContext, ContextCallback callback, Object state, Boolean
ignoreSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext
executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()
*/

Thanks for your help with this.

  Patrick Earl
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] System.Data.SQLite Reserved Words Bug

2011-07-09 Thread Joe Mistachkin

Patrick Earl wrote:

 System.Resources.MissingManifestResourceException was unhandled
   Message=Could not find any resources appropriate for the specified
 culture or the neutral culture.  Make sure
 System.Data.SQLite.SR.resources was correctly embedded or linked
 into assembly System.Data.SQLite at compile time, or that all the
 satellite assemblies required are loadable and fully signed.
 

This issue appears to be caused by an incorrect resource name in the
mixed-mode assembly compiled with VS 2010.  The following line in the
project file SQLite.Interop.2010.vcxproj is incorrect:

LogicalName$(IntDir)System.Data.SQLite.%(Filename).resources/LogicalName

It should read:

LogicalNameSystem.Data.SQLite.%(Filename).resources/LogicalName

This issue has been fixed in:

http://system.data.sqlite.org/index.html/ci/55f56ce508

Thanks for pointing out this problem.

--
Joe Mistachkin

___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Can a sys admin control temporary file location without changing the source code?

2011-07-09 Thread Tom Browder
On Thu, Jun 30, 2011 at 15:02, Stephan Beal sgb...@googlemail.com wrote:
 On Thu, Jun 30, 2011 at 9:52 PM, Tom Browder tom.brow...@gmail.com wrote:

 But I think the journal file is the problem...as I understand it, it
 has to be on disk, doesn't it?

The answer seems to be yes.

I have solved my problem by defining an explicit directory for my
sqlite db files and making sure that directory is writable by my web
server.  I make sure that the directory is not used for anything else
in order to help secure my web site.

Best regards,

-Tom
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Can a sys admin control temporary file location without changing the source code?

2011-07-09 Thread Stephan Beal
On Sun, Jul 10, 2011 at 4:25 AM, Tom Browder tom.brow...@gmail.com wrote:

 sqlite db files and making sure that directory is writable by my web
 server.  I make sure that the directory is not used for anything else
 in order to help secure my web site.


Another tip for such uses:

.htaccess:

 Files ~ \.sqlite3$ (or however your db is named)
Order allow,deny
Deny from all
/Files

so that people who know the db is there can't fetch it over http.

-- 
- stephan beal
http://wanderinghorse.net/home/stephan/
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users