views:

16

answers:

0

I am using sqlmetal on Ubuntu Linux and want to generate the dbml for a sqlite database that has just 2 tables created as follows:

CREATE TABLE "user" ( "uid" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" TEXT NOT NULL );

CREATE TABLE "bridge" ( "pkey" INTEGER NOT NULL, "rkey" INTEGER NOT NULL, "location" TEXT, PRIMARY KEY (pkey), CONSTRAINT "fk_bridge" FOREIGN KEY (rkey) REFERENCES user(uid));

I run sqlmetal as follows: $ sqlmetal /provider=Sqlite /conn "Data Source=./MySampleDb.sq3" /database=MySampleDb /dbml=mysampledb.dbml

I get the following output and no dbml file was generated:

DbLinq Database mapping generator 2008 version 0.20 for Microsoft (R) .NET Framework version 3.5 Distributed under the MIT license (http://linq.to/db/license)

Reading schema from SQLite database sqlmetal: The given key was not present in the dictionary.

Can someone tell me what I'm doing wrong or how to fix it?

Thanks.