<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Start using fds, what is the difference between fds_record_write and fds_record_update?</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/17177/start-using-fds-what-is-the-difference-between-fds_record_write-and-fds_record_update</link><description>With the same file id and record id,
do these two functions do the same thing? 
 Thanks 
 Paul</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Thu, 20 Oct 2016 07:17:26 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/17177/start-using-fds-what-is-the-difference-between-fds_record_write-and-fds_record_update" /><item><title>RE: Start using fds, what is the difference between fds_record_write and fds_record_update?</title><link>https://devzone.nordicsemi.com/thread/65985?ContentTypeID=1</link><pubDate>Thu, 20 Oct 2016 07:17:26 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6c6491c3-4537-488b-b523-cbf31ca0d9d5</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;No, as described in the &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v12.0.0/lib_fds_functionality.html?cp=4_0_0_3_31_0"&gt;FDS Library documentation&lt;/a&gt;, it is possible to have multiple records with the same FILE_ID and RECORD_ID. If you call &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v12.0.0/group__fds.html?cp=4_0_0_6_8_8_29#gac5f0ae356868529af04dc49815e534b0"&gt;&lt;code&gt;fds_record_write()&lt;/code&gt;&lt;/a&gt;, it will only create a new record, meaning you will have two record with the same RECORD_ID. &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v12.0.0/group__fds.html?cp=4_0_0_6_8_8_28#gabed63ec9b99aa4307d92499177320335"&gt;&lt;code&gt;fds_record_update()&lt;/code&gt;&lt;/a&gt; on the other hand, will create a new record and then invalidate the old record, leaving you with only one record.&lt;/p&gt;
&lt;p&gt;When calling &lt;code&gt;fds_record_update()&lt;/code&gt;, the parameter &lt;em&gt;p_desc&lt;/em&gt; must point to the old record to be invalidated. On return, &lt;em&gt;p_desc&lt;/em&gt; will point to the new record, similar to the return of &lt;code&gt;fds_record_write()&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Jørgen&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>