Jon:
I found the problem, if i use
sqlmetal /provider:Sqlite /conn:Uri=file:/home/luciano/Test.sqlite /
code:/home/luciano/Projects/TestLinq/TestLinq/Output.cs /case:NET /
language:C\#2 /namespace:TestLinq.DbLinq /culture:en
it use DbLinq.. namespace,
if i erase */namespace:TestLinq.DbLinq* the output file is correct, do
i fill a bug report? Where? in this group or mono?
Thanks
On 15 feb, 21:33, Lucianoc <[email protected]> wrote:
> Hi jon:
> I'm using sqlmetal included with mono 2.6.1. I test it with
> sqlite and mysql and the problem is the same.
>
> The parameters supplied to sqlmetal are:
>
> /provider:Sqlite /conn:Uri=file:/home/luciano/Test.sqlite /code:/home/
> luciano/Projects/TestLinq/TestLinq/Output.cs /case:NET /language:C\#2 /
> namespace:TestLinq.DbLinq /culture:en
>
> The sqlite database is a tiny test with 2 tables (Table 1 (columns
> id ; name) Table2 (columns id; name).
>
> I'm seeing this code on mono 2.6.1 source.
>
> #if MONO_STRICT
> writer.WriteUsingNamespace("System.Data.Linq");
> #else
> writer.WriteLine("#if MONO_STRICT");
> writer.WriteUsingNamespace("System.Data.Linq");
> writer.WriteLine("#else // MONO_STRICT");
> writer.WriteUsingNamespace("DbLinq.Data.Linq");
> writer.WriteUsingNamespace("DbLinq.Vendor");
> writer.WriteLine("#endif // MONO_STRICT");
> #endif
>
> So, if MONO_STRICT is present this should not happen at all. Is this
> defined?
>
> Any thought?
>
> Thanks.
>
> On 15 feb, 17:12, Jonathan Pryor <[email protected]> wrote:
>
>
>
> > On Mon, 2010-02-15 at 04:59 -0800, Lucianoc wrote:
> > > I'm writing an addin for mono to use sql metal to generate
> > > output file through sqlmetal which is included with mono 2.6. The
> > > output file have a reference to DbLinq assembly's (using DbLinq...;)
> > > and if i don't misunderstand DbLinq assembly's aren't present at mono.
>
> > This sounds like:
>
> > http://groups.google.com/group/dblinq/msg/3588f10b005e27dc
>
> > How are you generating this file?
>
> > Specifically, DbLinq's assemblies should NOT be included with Mono (nor
> > are they). Instead, we one of two things is supposed to happen:
>
> > 1. If you use DbMetal to generate the file, a MONO_STRICT define is
> > supposed to be present which surrounds all use of DbLinq namespaces.
> > This allows using normal DbLinq normally (don't #define MONO_STRICT)
> > and against Mono (#define MONO_STRICT); this is primarily useful
> > for the unit tests
>
> > 2. If you use SqlMetal, the DbLinq namespaces should not be referenced
> > at all.
>
> > At least, this is how it behaves for me, but it seems that there is
> > something I'm missing somewhere.
>
> > Could you tell me what you're executing, exactly, and against which
> > database/etc. that is generating a file that won't compile?
>
> > > Is this correct? Could sqlmetal generated files be executed on mono
> > > without any other installation besides mono itself?
>
> > That is correct, sqlmetal-generated files should execute on mono without
> > any other software being present (as Mono's System.Data.Linq.dll should
> > contain everything that's needed to get sqlmetal-generated files to
> > work).
>
> > - Jon
--
You received this message because you are subscribed to the Google Groups
"DbLinq" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/dblinq?hl=en.