Failure Building Partial Class


Author
Message
Guillermo Vilas
Guillermo Vilas
StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)
Group: StrataFrame Users
Posts: 112, Visits: 2.3K
Hello

Trying to build the partial class of a BO I'm getting the message shown in the attachment. I can't figure out where's the error. I checked the table and for example the mapping of the table in the Business Object Mapper Window is not correct,

The column that header "Null Type" saids that all the fields are not Nullable but in database table is the opposite of that.



Is the first time I see this kind error. The database was created using the Database Deployment Toolkit.



I will try creating the table manually to see what happens.

------------------------------------------------------------------------
I would like to change the world, but they don´t give me the source code.
MS Windows 7 Ultimate 64-Bit
Intel(R) Core(TM)2 Quad CPU Q9300 2.50 GHz
6.00 GB of RAM, NVIDIA GeForce 9800 GT

MacBook Pro i5 OSX Lion
Attachments
BOError.jpg (129 views, 37.00 KB)
BOError2.jpg (132 views, 98.00 KB)
StrataFrame Team
S
StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)StrataFrame Developer (6.5K reputation)
Group: StrataFrame Developers
Posts: 3K, Visits: 2.5K
The column that header "Null Type" saids that all the fields are not Nullable but in database table is the opposite of that.

Those are actually independent.  The value for the "Null Type" of the business object properties does not always match the value of the "Allow Nulls" in the database.  The "Null Type" for the BO field determines how the Get/Set of the field property will handle a DBNull.Value property that it encounters.  Those values are pulled from the StrataFrame database meta-data and are not retrieved from SQL Server.

As to the error you are receiving, I am not sure... Is the business object mapped to a DDT source or directly to SQL Server? 

Guillermo Vilas
Guillermo Vilas
StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)StrataFrame User (294 reputation)
Group: StrataFrame Users
Posts: 112, Visits: 2.3K
Hello Ben

The "Null Type" topic was my mistake, sorry for that.
I have the Business Object created in the same Windows Application and mapped to the DDT I also tested mapping it to the Development Sever with the same results.

So I created a Business object library apart from the Windows project and the added a new Business Object class. The result for the mapping was successful then. So I guess the mapping is not working if the class is inside the Windows project itself, at least for me.

------------------------------------------------------------------------
I would like to change the world, but they don´t give me the source code.
MS Windows 7 Ultimate 64-Bit
Intel(R) Core(TM)2 Quad CPU Q9300 2.50 GHz
6.00 GB of RAM, NVIDIA GeForce 9800 GT

MacBook Pro i5 OSX Lion

Trent Taylor
Trent Taylor
StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 7K
Guillermo,

I think that you have something else going on here.  The BOs work the same in an application as they would in a BO library.  So that you can troubleshoot where you are having a problem, create a new SF Application, add a BO, map it and build the project and you will see that it works without issue.  You can then start bringing over your BOs one at a time to see what the problem was.  It could be that your Windows App was not created as an SF application or you could be missing some references.  Regardless, it is always best to store your BOs in a library instead of the App assembly anyway.  Glad you got it going Smile

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search