<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://sqlserver.ro/utility/FeedStylesheets/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/"><channel><title>Diverse</title><link>http://sqlserver.ro/forums/27/ShowForum.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2.1 SP2 (Build: 61129.1)</generator><item><title>Re: URGENT!!! - refacere date pe baza undei tabele de back-up</title><link>http://sqlserver.ro/forums/thread/7672.aspx</link><pubDate>Mon, 12 Oct 2009 10:59:20 GMT</pubDate><guid isPermaLink="false">963f3a18-65dd-4aad-905c-b785cfe1d7c7:7672</guid><dc:creator>victordomain</dc:creator><slash:comments>0</slash:comments><comments>http://sqlserver.ro/forums/thread/7672.aspx</comments><wfw:commentRss>http://sqlserver.ro/forums/commentrss.aspx?SectionID=27&amp;PostID=7672</wfw:commentRss><description>Am folosit solutia si a functionat.&lt;br /&gt;&lt;br /&gt;Multumesc&lt;br /&gt;&lt;br /&gt;Victor&lt;br /&gt;&lt;br /&gt;Topic closed, user happy!</description></item><item><title>Re: URGENT!!! - refacere date pe baza undei tabele de back-up</title><link>http://sqlserver.ro/forums/thread/7671.aspx</link><pubDate>Mon, 12 Oct 2009 10:49:59 GMT</pubDate><guid isPermaLink="false">963f3a18-65dd-4aad-905c-b785cfe1d7c7:7671</guid><dc:creator>Diana</dc:creator><slash:comments>0</slash:comments><comments>http://sqlserver.ro/forums/thread/7671.aspx</comments><wfw:commentRss>http://sqlserver.ro/forums/commentrss.aspx?SectionID=27&amp;PostID=7671</wfw:commentRss><description>Daca folosesti SQL 2005 vezi si&lt;br /&gt;http://pratchev.blogspot.com/2008/03/updates-with-cte.html&lt;br /&gt;Incepand cu SQL 2008 poti folosi statement-ul "MERGE".</description></item><item><title>Re: URGENT!!! - refacere date pe baza undei tabele de back-up</title><link>http://sqlserver.ro/forums/thread/7670.aspx</link><pubDate>Mon, 12 Oct 2009 10:36:58 GMT</pubDate><guid isPermaLink="false">963f3a18-65dd-4aad-905c-b785cfe1d7c7:7670</guid><dc:creator>ignatandrei</dc:creator><slash:comments>0</slash:comments><comments>http://sqlserver.ro/forums/thread/7670.aspx</comments><wfw:commentRss>http://sqlserver.ro/forums/commentrss.aspx?SectionID=27&amp;PostID=7670</wfw:commentRss><description>incearca&amp;nbsp; :&lt;br&gt;&lt;br&gt;begin transaction trx&lt;br&gt;--verificare&lt;br&gt;select top 100 id,&amp;nbsp; numar from facturi order by id &lt;br&gt;&lt;br&gt;update Facturi&amp;nbsp;
set numar = fb.numar&lt;br&gt;from Facturi inner join Facturi_backup fb on Facturi.id=fb.id&lt;br&gt;&lt;br&gt;--verificare&lt;br&gt;
select top 100 id,&amp;nbsp; numar from facturi order by id &lt;br&gt;
&lt;br&gt;rollback transaction&amp;nbsp; trx&lt;br&gt;</description></item><item><title>URGENT!!! - refacere date pe baza undei tabele de back-up</title><link>http://sqlserver.ro/forums/thread/7669.aspx</link><pubDate>Mon, 12 Oct 2009 10:07:09 GMT</pubDate><guid isPermaLink="false">963f3a18-65dd-4aad-905c-b785cfe1d7c7:7669</guid><dc:creator>victordomain</dc:creator><slash:comments>0</slash:comments><comments>http://sqlserver.ro/forums/thread/7669.aspx</comments><wfw:commentRss>http://sqlserver.ro/forums/commentrss.aspx?SectionID=27&amp;PostID=7669</wfw:commentRss><description>Buna ziua,&lt;br /&gt;&lt;br /&gt;Avem tabelele:&lt;br /&gt;&lt;br /&gt;Facturi&lt;br /&gt;id - int&lt;br /&gt;numar - int&lt;br /&gt;&lt;br /&gt;Facturi_backup&lt;br /&gt;id - int&lt;br /&gt;numar - int&lt;br /&gt;&lt;br /&gt;Dintr-o greseala (update Facturi set numar = 1023), toate numerele de factura din tabela facturi sunt acum 1023. &lt;br /&gt;&lt;br /&gt;Partea buna ca am un back-up mai vechi si pot reface majoritatea numerelor de factura.&lt;br /&gt;&lt;br /&gt;Intrebarea mea este: Care e comanda care imi preia numerele de factura din tabela Facturi_backup in functie de id si-mi updateaza tabela Facturi astfel incat sa pot reface acele numere de factura. ID-urile nu sunt afectate si ne putem baza pe ele.&lt;br /&gt;&lt;br /&gt;Multumesc... e cam..urgent :).</description></item></channel></rss>