What happens is that it doesn't allow multiple entries for that pro_id. I'm
not able to understand why that is happening.


On Mon, Mar 14, 2011 at 8:48 PM, Kostya Vasilyev <[email protected]> wrote:

> 14.03.2011 17:36, Brad Stintson пишет:
>
>  I assigned pre-defined  value for foregin key. The thing that happens is
>> that on first time use of that key, an entry is created in database. But if
>> I use that value for second time then value is not updated in database
>>
>
> Brad,
>
> Not sure if I understand what you meant about predefined values.
>
> The basic idea is: every time you insert a new row into "table event", make
> sure that "pro_id" is set to one of the existing values of "_id" in "table
> profile".
>
> For updates, use the "_id" in "table event" to identify the row you're
> updating, and either leave the "pro_id" alone (thus keeping the old value)
> or set it to a valid "_id" in "table profile".
>
>
> --
> Kostya Vasilyev -- http://kmansoft.wordpress.com
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" 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/android-developers?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" 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/android-developers?hl=en

Reply via email to