<div dir="ltr">On Tue, Jul 15, 2008 at 3:33 PM, Nick Morrott &lt;<a href="mailto:knowledgejunkie@gmail.com">knowledgejunkie@gmail.com</a>&gt; wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
2008/7/15 C D Waddell &lt;<a href="mailto:cdwaddell@gmail.com">cdwaddell@gmail.com</a>&gt;:<br>
<div><div></div><div class="Wj3C7c">&gt; I was having an issue with my server and had to migrate to a new myth-tv<br>
&gt; backend box. So I followed the directions at<br>
&gt; <a href="http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.7" target="_blank">http://mythtv.org/docs/mythtv-HOWTO-23.html#ss23.7</a> , I installed the exact<br>
&gt; same version of mythtv onto my new system (the latest unmasked Gentoo<br>
&gt; version) but when I ran the commands:<br>
&gt;<br>
&gt; $ mysql -u mythtv -pmythtv mythconverg &lt; record.sql<br>
&gt;<br>
&gt; and<br>
&gt;<br>
&gt; $ mysql -u mythtv -pmythtv mythconverg &lt; recorded.sql<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; I got the error:<br>
&gt;<br>
&gt; ERROR 1136 (21S01) at line 24: Column count doesn&#39;t match value count at row<br>
&gt; 27<br>
&gt;<br>
&gt; I know that I could have avoided this by issuing the mysqldump -c command<br>
&gt; for the export of the data, but this wasn&#39;t in the documentation and I<br>
&gt; didn&#39;t think about it until after my old box was inaccessible. Is there<br>
&gt; anything that I can do to get these two tables into my new system? Is there<br>
&gt; a place I can go to look at the database schema changes to determine what<br>
&gt; columns no longer match?<br>
<br>
</div></div>The best place is your database, either via the mysql command line or<br>
using an interface such as phpMyAdmin.<br>
<br>
If using the mysql command line (update user for correct mysql username):<br>
<br>
$ mysql -u mythtv -p mythconverg<br>
&lt;enter password&gt;<br>
<br>
mysql&gt; describe record;<br>
mysql&gt; describe recorded;<br>
<br>
will show the current fields in those tables. Compare those to the<br>
insert/replace fields in your two export files and you&#39;ll be able to<br>
spot which field is missing.<br>
<br>
To monitor updates to the DB schema over time, check<br>
<a href="http://cvs.mythtv.org/trac/log/branches/release-0-21-fixes/mythtv/libs/libmythtv/dbcheck.cpp" target="_blank">http://cvs.mythtv.org/trac/log/branches/release-0-21-fixes/mythtv/libs/libmythtv/dbcheck.cpp</a><br>
(replace brnaches/release-0-21-fixes/ with /trunk if running trunk)<br>
<br>
Finally, recent versions of MythTV keep a backup of the DB before<br>
upgrading to a new version, so check your DB storage directory<br>
(default to recordings directory if not configured) for a recent<br>
backup, which may be usable. If you do replace your current DB with<br>
the backup, MythTV should be able to upgrade to the current schema<br>
without any issues.<br>
<br>
Nick<br>
<br>
--<br>
Nick Morrott<br>
<br>
MythTV Official wiki:<br>
<a href="http://mythtv.org/wiki/" target="_blank">http://mythtv.org/wiki/</a><br>
MythTV users list archive:<br>
<a href="http://www.gossamer-threads.com/lists/mythtv/users" target="_blank">http://www.gossamer-threads.com/lists/mythtv/users</a><br>
<br>
&quot;An investment in knowledge always pays the best interest.&quot; - Benjamin Franklin<br>
_______________________________________________<br>
mythtv-users mailing list<br>
<a href="mailto:mythtv-users@mythtv.org">mythtv-users@mythtv.org</a><br>
<a href="http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users" target="_blank">http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-users</a><br>
</blockquote></div><br>Thanks for the DB schema link, I was able to solve my problem using this. Once I went through the schema I saw that profiles were added in .21, and remembered that I had to switch to a testing version of mythtv .21 for a short time in order to solve an incompatibility issue with my hardware and give me access to schedules direct. Since the version of mythtv that I was using was .20, the db schema was update. Thus when I tried to import my data the columns were missing. Once I removed the &quot;profile&quot; section from the dump, the import went smoothly. <br>
<br>Thanks,<br>CD Waddell<br>
</div>