Exception during the execution of an action query

Posts   
 
    
nachanga
User
Posts: 13
Joined: 16-Sep-2005
# Posted on: 23-Sep-2005 10:36:24   

Hi,

I'm new to LLBLGen Pro but i like what i've seen so far, specially this support forum which is really good.

I'm trying to use LLBLGen 1.0.2005.1 Beta to access an SqlServer Ce db in a PocketPc. Since LLBLGen cannot read the schema from SqlServerCe I have to create the tables in my DesktopPC then I have to create the exact same tables in the PocketPc. This is really painfull and very error prone since I'm never sure if I made identical tables on DesktopPC and PocketPC. ¿There is another way to develop this kind of applications?

But when I run the application I get the following Exception:

'SD.LLBLGen.Pro.ORMSupportClasses.ORMQueryExecutionException' occurred in SmartDeviceApplication1.exe Additional information: An exception was caught during the execution of an action query: . Check InnerException, QueryExecuted and Parameters of this exception to examine the cause of this exception.

After watching the exception I got the QueryExecuted:

INSERT INTO "forums_Censorship" ("Word","Replacement") VALUES (?,?) Parameter: @Word: String. Lenght: 20. Precision: 0. Direction: Input. Value: asshole. Parameter: @Replacement: String. Lenght: 20. Precision: 0. Scale: 0. Direction: Input. Value: ---. This is all the code I used:

private void button1_Click(object sender, System.EventArgs e)
{
    ForumsCensorshipEntity ent= new ForumsCensorshipEntity("asshole");
    DataAccessAdapter a=new DataAccessAdapter("Data Source=\\My Documents\\Forums");
    ent.Replacement="---";
    try
    {
        a.SaveEntity(ent); //Exception Here.
    }
    catch(Exception ex)
    {
        ex.GetType();
        throw ex;
    }
}

Thank you in advance.

nachanga
User
Posts: 13
Joined: 16-Sep-2005
# Posted on: 23-Sep-2005 13:41:27   

Hi Frans,

The problem was that the name of the table in the PocketPc was not exactly the same.

After I found that, I was able to write and read from the database. I'm so excited!! simple_smile

CompactFrame is not the best environment, but I hope it will improve soon. It's a growing plataform and it will be more present in our lives in the near future.

LLBLGen seems to work so i will keep using it. stuck_out_tongue_winking_eye

Thank you very much for your support. smile

-Nacho

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39862
Joined: 17-Aug-2003
# Posted on: 23-Sep-2005 15:05:33   

nachanga wrote:

Hi Frans,

The problem was that the name of the table in the PocketPc was not exactly the same.

Ah! Who would have thought after the insightful error message from SqlServerCE: "" wink

After I found that, I was able to write and read from the database. I'm so excited!! simple_smile

hehe simple_smile I'm glad you still are after working with the CF.NET framework smile

CompactFrame is not the best environment, but I hope it will improve soon. It's a growing plataform and it will be more present in our lives in the near future.

yes I read v2.0 will be much better (isn't it always better in the next release wink ). Let's hope it indeed is simple_smile

If you run into more problems, please post them in the beta forum so I can fix/solve them simple_smile

Frans Bouma | Lead developer LLBLGen Pro