Setting field to Null

Posts   
 
    
Fishy avatar
Fishy
User
Posts: 392
Joined: 15-Apr-2004
# Posted on: 09-Aug-2005 21:27:57   

Hi,

I'm trying to set a field to null using the following:

                score.SetNewFieldValue(CType(ScoreFieldIndex.SpecialScoreIdent, Integer), Nothing)
    SaveEntity(score)


Now the actual value has not changed. In the db it is a null, the entity value is 0 (which is the default null value, 0 does not exist in the pk table). When I do the update it baulks because 0 is not in the specialScore table.

Any ideas?

Fishy

Fishy avatar
Fishy
User
Posts: 392
Joined: 15-Apr-2004
# Posted on: 09-Aug-2005 21:55:38   

I figured out my problem. I was saving the wrong copy of the Score flushed

Sorry to waste anybody's time.

Fishy

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39933
Joined: 17-Aug-2003
# Posted on: 09-Aug-2005 23:41:21   

glad it's solved!

Frans Bouma | Lead developer LLBLGen Pro