<div dir="ltr">Hi Yavuz,<div><br></div><div>the &quot;problem&quot; is that the &#39;null&#39; (for telephone on the first object) is, in Cocoa/ObjC mapped to NSNull. However, NSNull is, unfortunately, not a &quot;valid&quot; PList object/type.</div>
<div>A work around, on your server, would be to do something like:  &quot;telephone&quot; =&gt; &quot;NULL&quot;, or simply exclude all keys where values are &quot;NULL&quot;... :-/<br></div><div><br></div><div style>There are ways how we could fix it on the library:</div>
<div style>* exclude every key, where value is NSNull (which makes the value &#39;nil&#39; (not NSNull)</div><div style>* see if new &#39;store&#39; could be written, that simply uses NSJSONSerialization, to store JSON on the &quot;filesystem&quot;</div>
<div><br></div><div style>I will create a JIRA ticket for this issue.</div><div style><br></div><div style>Thanks for the feedback.</div><div style><br></div><div style>-M</div><div><br></div></div><div class="gmail_extra">
<br><br><div class="gmail_quote">On Wed, Jun 12, 2013 at 7:52 PM, Yavuz Selim YILMAZ <span dir="ltr">&lt;<a href="mailto:yavuzsel@buffalo.edu" target="_blank">yavuzsel@buffalo.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">here is my response object from log:<div><br></div><div><div> ({</div><div>        id = 1;</div><div>        mail = &quot;<a href="mailto:yavuzsel@buffalo.edu" target="_blank">yavuzsel@buffalo.edu</a>&quot;;</div>
<div>        name = &quot;yavuz&quot;;</div><div>        telephone = &quot;&lt;null&gt;&quot;;</div><div>    },</div><div>    {</div><div>        id = 2;</div><div>        mail = &quot;<a href="mailto:yavuzsel@buffalo.edu" target="_blank">yavuzsel@buffalo.edu</a>&quot;;</div>
<div>        name = &quot;yavuzsel&quot;;</div><div>        telephone = &quot;001234&quot;;</div><div>    }</div><div>)</div><div><br></div><div>thanks,</div><div class="im"><div>
<div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">
<br>---</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">
Yavuz Selim Yilmaz</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">
SUNY at Buffalo</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">
Computer Science and Engineering</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">
PhD Candidate</div>
</div>
<br></div><div><div><div class="h5"><div>On Jun 12, 2013, at 1:49 PM, Matthias Wessendorf &lt;<a href="mailto:matzew@apache.org" target="_blank">matzew@apache.org</a>&gt; wrote:</div><br></div></div><blockquote type="cite">
<div><div class="h5">can u NSLog the &#39;<font><span style="line-height:normal;background-color:rgba(255,255,255,0)">responseObject&#39;?</span></font><br><br>Is that a NSDictionary or NSArray?<div><br></div><div><span></span><br>
<br>On Wednesday, June 12, 2013, Yavuz Selim YILMAZ  wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">Hi all,<div><br></div><div>I am getting error while saving my response object to my store. Here are my codes:</div>

<div><br></div><div><br></div><div><div>AGPipeline *pipeline = [AGPipeline pipelineWithBaseURL:[NSURL URLWithString:@&quot;localhost&quot;]];</div><div><br></div><div>id&lt;AGPipe&gt; dataPipe = [pipeline pipe:^(id&lt;AGPipeConfig&gt; config) {</div>

<div>            [config setName:@&quot;persons&quot;];</div><div>            [config setEndpoint:@&quot;get_persons.php&quot;];</div><div>        }];</div><div>        </div><div>AGDataManager *dm = [AGDataManager manager];</div>

<div><br></div><div>id&lt;AGStore&gt; dataStore = [dm store:^(id&lt;AGStoreConfig&gt; config) {</div><div>        [config setName:@&quot;persons&quot;];</div><div>        [config setType:@&quot;PLIST&quot;];</div><div>    }];</div>

<div>    </div><div>[dataPipe read:^(id responseObject) {</div><div>        NSError *error;</div><div>        if (![dataStore save:responseObject error:&amp;error])</div><div>            NSLog(@&quot;Save: An error occured during save! \n%@&quot;, error);</div>

<div>            </div><div>    } failure:^(NSError *error) {</div><div>        NSLog(@&quot;An error has occured during read! \n%@&quot;, error);</div><div>    }];</div><div>    </div><div>    </div><div>And I am getting this log output:</div>

<div><br></div><div>Save: An error occured during save! </div><div>Error Domain=org.aerogear.stores.save Code=0 &quot;error on save&quot; UserInfo=0x727a6e0 {NSLocalizedDescription=error on save}</div><div><br></div><div>

<br></div><div>here is my &quot;get_persons.php&quot;</div><div><br></div><div>&lt;?php<span style="white-space:pre-wrap">        </span></div><div>    $result_array = array(array(</div><div>                        &quot;id&quot; =&gt; 1,</div>

<div>                        &quot;name&quot; =&gt; &quot;yavuz&quot;,</div><div>                        &quot;mail&quot; =&gt; &quot;<a>yavuzsel@buffalo.edu</a>&quot;,</div>
<div>                        &quot;telephone&quot; =&gt; NULL</div><div>                    ),</div><div>                    array(</div><div>                        &quot;id&quot; =&gt; 2,</div><div>                        &quot;name&quot; =&gt; &quot;yavuzsel&quot;,</div>

<div>                        &quot;mail&quot; =&gt; &quot;<a>yavuzsel@buffalo.edu</a>&quot;,</div><div>                        &quot;telephone&quot; =&gt; &quot;001234&quot;</div>
<div>                    ));</div><div>    header(&#39;HTTP/1.1 200 OK&#39;);</div><div>    header(&#39;content-type: application/json&#39;);</div><div>    echo json_encode($result_array);</div><div>?&gt;</div><div><br></div>

<div><br></div><div>
<div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

Any help or direction is appreciated.</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

<br></div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

Cheers,</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

<br>---</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

Yavuz Selim Yilmaz</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

SUNY at Buffalo</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

Computer Science and Engineering</div><div style="text-indent:0px;letter-spacing:normal;font-variant:normal;text-align:-webkit-auto;font-style:normal;font-weight:normal;line-height:normal;text-transform:none;font-size:medium;white-space:normal;font-family:Helvetica;word-spacing:0px">

PhD Candidate</div>
</div>
<br></div></div></blockquote></div><br><br>-- <br>Matthias Wessendorf <br><br>blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>

twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a><br></div></div>
_______________________________________________<br>aerogear-dev mailing list<br><a href="mailto:aerogear-dev@lists.jboss.org" target="_blank">aerogear-dev@lists.jboss.org</a><br><a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a></blockquote>
</div><br></div></div><br>_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br></blockquote></div><br><br clear="all"><div><br></div>-- <br>Matthias Wessendorf <br>
<br>blog: <a href="http://matthiaswessendorf.wordpress.com/" target="_blank">http://matthiaswessendorf.wordpress.com/</a><br>sessions: <a href="http://www.slideshare.net/mwessendorf" target="_blank">http://www.slideshare.net/mwessendorf</a><br>
twitter: <a href="http://twitter.com/mwessendorf" target="_blank">http://twitter.com/mwessendorf</a>
</div>