Questions tagged [dbmetal]
12 questions
3
votes
1 answer
How can i use DBLinq >> DBMetal tool with sqlite?
Please provide samples of command line tool dbmetal to generate code file from a sqlite database.

Jitesh Patil
- 1,334
- 1
- 8
- 13
2
votes
1 answer
DBMetal generating an invalid class for sqlite_sequence
I'm using DBLinq and DBMetal.exe to generate Linq-to-SQL like classes off an SQLite database. Every time I use DBMetal to regenerate my DataContext, it generates a class for sqlite_sequence. The trouble is is that sqlite_sequence isn't a proper…

sgwill
- 9,814
- 8
- 35
- 40
1
vote
0 answers
Change class name in pre-build event
Possible Duplicate:
How to set the DataContext class name with DbMetal?
I use DbMetal in my pre-build event to generate the desired code file. DbMetal generates a class called Main. In its wiki I can'f find a parameter to change that default…

fjdumont
- 1,517
- 1
- 9
- 22
1
vote
1 answer
How to serialize instances of classes generated by DbMetal?
I noticed DbMetal generates classes that don't implement the ISerializable interface, nor are marked with DataContractAttribute. What is the easiest way of serializing such classes? Is there any DbMetal parameter that could help me?

Jader Dias
- 88,211
- 155
- 421
- 625
1
vote
1 answer
How to set the DataContext class name with DbMetal?
DbLinq's DbMetal generates a Main class which inherits DataContext. I don't want it to be Main. How to change that?

Jader Dias
- 88,211
- 155
- 421
- 625
1
vote
1 answer
Why does DbMetal Generate Table Attribute with "main"?
I'm a newbie with DBLink and Sqlite. When DbMetal generates Nortwind.cs (C#) it marks some methods with a Table attribute:
[Table(Name="main.Categories")] // C#
After I used DbMetal to create a Nortwind.vb (VB.Net) file, the test program aborted…

BSalita
- 8,420
- 10
- 51
- 68
1
vote
1 answer
DbMetal chokes on repeated foreign key references in SQLite - any ideas?
I've been struggling to get DbMetal to process my SQLite database. I finally isolated the problem. It won't allow a table to have two foreign key references to the same column.
For example, a SQLite database with these two tables will fail:
CREATE…

devuxer
- 41,681
- 47
- 180
- 292
1
vote
2 answers
Equal is not defined between type Nullable and Int32
I am writing a boring application to manage patients and their clinic history. I used SQLite combined with DbLinq libraries and DbMetal code generation utility. Here are two classes from the genereated code extracted from the underlying…

Totem
- 454
- 5
- 18
0
votes
1 answer
CodeConditionStatement and Nullable.Equals
I have to create the following VB.Net code through a C# CodeConditionStatement
If Not Nullable.Equals(field.Name, Value) Then
...
End If
What I alredy tried was
var property = new CodeMemberProperty();
CodeExpression condition = new…

mr.moe
- 75
- 4
0
votes
1 answer
DBMetal (SQLite): "Sequence contains more than one element" with multiple foreign keys
When trying to create a C# file using DbMetal (as part of DbLinq), I get the following error:
DbMetal: Sequence contains more than one element
It's only appearing when I reference multiple foreign keys as part of my primary key. The following is…

Will Eddins
- 13,628
- 5
- 51
- 85
0
votes
1 answer
DbLinq DbMetal - "The given key was not present in the dictionary" when adding Foreign Key
This is my initial SQLite database
CREATE TABLE [Categories] (
[ParentId] INT,
[Name] VARCHAR(100));
CREATE TABLE [Fees] (
[CategoryId] INT,
[Name] VARCHAR(100),
[Value] VARCHAR(50),
[Info] VARCHAR(200));
CREATE TABLE [Markups] (
…

Aximili
- 28,626
- 56
- 157
- 216
-2
votes
1 answer
C# linq and multilingual database
In my application has a multilingual database. It is necessary to load the lists from the database of the language which is set in the user program. I use Dbling library and now 3 days scratching their heads, how to dynamically take the data from a…

murash
- 211
- 3
- 14