LinHES Forums http://forums.linhes.org/ |
|
myth 0.19- fixes now failing to save edits http://forums.linhes.org/viewtopic.php?f=17&t=9811 |
Page 1 of 1 |
Author: | jimhayes [ Wed Apr 26, 2006 1:53 pm ] |
Post subject: | myth 0.19- fixes now failing to save edits |
I'm a bit perplexed at this one, it used to work fine and I'm not aware of having changed anything, nor are there any obvious errors in either the front or backend outputs. but, when I go to edit a recording, add some cutpoints, exit edit mode and then re-enter it, my edit points are lost. perhaps I'm being really stupid, but i'm pretty sure it used to work fine like that. Anyone got any clues as to where I might look? I suspected a database problem, I note I had over a million entries in the recordedmarkup table. I emptied that (reckless, but i did back it up first), now I can't edit at all before running mythcomflag --rebuild on the affected file (no problem, I'm doing all of them now). When thats done, the problem remains the same. Thanks in advance, Jim. |
Author: | Fidelis [ Wed Apr 26, 2006 2:55 pm ] |
Post subject: | |
Jim, I'm fairly sure you always had to save your changes/edits by hitting "?" while in edit mode. (And for clarity's sake, I do mean shift + / )I've used R5 16, 26, 30.1, 30.2, and B7 and it's been the same throughout (thus far, anyway). Here's a very brief article on the basic of editing: http://knoppmythwiki.org/index.php?page=VideoEditHowTo Also, just for learning's sake, here's another section of the wiki I'm always checking for info: http://knoppmythwiki.org/index.php?id=HowTo |
Author: | Greg Frost [ Wed Apr 26, 2006 4:23 pm ] |
Post subject: | |
I have never had to explicitly save cutpoints! |
Author: | jimhayes [ Wed Apr 26, 2006 4:33 pm ] |
Post subject: | |
Thanks, I'm pretty sure that wasn't necessary when it was working, but just the same i did check out the basics and thus also tried pressing ? to save edit list. I should have said that, apologies. However, still the same either way, no save of the edit list. I did let loose an svn build of mythtv on my laptop into my network a little while back, I have a suspicion that might have messed with my database. certainly the schema version is now marked as 1135, and I think it should have been about 1124 or so for 0.19-fixes. there were changes in cutlist handling around 1127/1128 I think, so perhaps that could have something to do with it. I'll see, but i have a feeling it could all be rather painful if thats the case ![]() If so, i'm surprised nothing else seems broken! live and learn. It's not necessarily so, however, so anyone that has experienced the same please do let me know, thanks. |
Author: | jimhayes [ Wed Apr 26, 2006 5:14 pm ] |
Post subject: | |
Yup, i managed to hose my own database .... from : http://svn.mythtv.org/trac/browser/trun ... bcheck.cpp this is the code that must have run for my schema version to have reached 1135 .... Quote: if (dbver == "1128")
2067 { 2068 2069 MSqlQuery query(MSqlQuery::InitCon()); 2070 query.prepare("SELECT chanid, starttime, cutlist FROM recorded" 2071 " WHERE LENGTH(cutlist) > 1;"); 2072 if (query.exec() && query.isActive() && query.size() > 0) 2073 { 2074 MSqlQuery insert(MSqlQuery::InitCon()); 2075 while (query.next()) 2076 { 2077 QString cutlist = query.value(2).toString(); 2078 2079 QStringList strlist = QStringList::split("\n", cutlist); 2080 QStringList::Iterator i; 2081 for (i = strlist.begin(); i != strlist.end(); ++i) 2082 { 2083 long long start = 0, end = 0; 2084 if (sscanf((*i).ascii(), "%lld - %lld", &start, &end) == 2) 2085 { 2086 insert.prepare( 2087 "INSERT INTO recordedmarkup (chanid, starttime," 2088 " type, mark) " 2089 "VALUES (:CHANID, :STARTTIME, :TYPE, :MARK);"); 2090 insert.bindValue(":CHANID", query.value(0).toString()); 2091 insert.bindValue(":STARTTIME", 2092 query.value(1).toDateTime()); 2093 2094 insert.bindValue(":TYPE", 1); 2095 insert.bindValue(":MARK", start); 2096 insert.exec(); 2097 2098 insert.bindValue(":TYPE", 0); 2099 insert.bindValue(":MARK", end); 2100 insert.exec(); 2101 } 2102 } 2103 } 2104 } 2105 2106 const QString updates[] = { 2107 "INSERT INTO recordedmarkup (chanid, starttime, type, mark) SELECT" 2108 " chanid, starttime, '2', bookmark FROM recorded WHERE bookmark <> 0;", 2109 "ALTER TABLE recorded CHANGE cutlist cutlist TINYINT(1) NOT NULL DEFAULT 0", 2110 "ALTER TABLE recorded CHANGE bookmark bookmark TINYINT(1) NOT NULL DEFAULT 0", 2111 "" 2112 }; 2113 if (!performActualUpdate(updates, "1129", dbver)) 2114 return false; 2115 } "ALTER TABLE recorded CHANGE cutlist cutlist TINYINT(1) NOT NULL DEFAULT 0" almost certainly means the cutlist field is now just a pointer as to whether one exists, rather than the actual cutlist itself. So my 0.19 program is trying to save another type(a string, I would guess)) to a tinyint field and fails (silently). Or something like that, anyway. I'll probably have to tweak it back to what it was before to get cutlists working again... Apologies for the noise, thanks for the replies, and the moral is to be a bit careful if you put a later build of myth on your network. I think mine picked up on an earlier config and tried (succesfully) to quietly update the master backend DB. Which is what it should do, in most instances, I guess. |
Author: | jimhayes [ Wed Apr 26, 2006 5:48 pm ] |
Post subject: | |
changing the type of the cutlist field back to "text" fixed it, should this precise issue ever happen to you. |
Author: | mac [ Sat Apr 29, 2006 1:54 am ] |
Post subject: | |
The joy of having the source to look at. Good detective work to save yourself from a reinstall! |
Page 1 of 1 | All times are UTC - 6 hours |
Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |