Re: [sqlite] SQL Newbie problem I guess...

2008-03-11 Thread Jonas Sandman
Thanks for the input. The 'Folder' vs 'Folders' problem was merely a spelling mistake here, not in the code. My problem was that '%' was being escaped in my code. Putting a '%%' fixed the problem. Regards, Jonas On Tue, Mar 11, 2008 at 5:37 PM, Dennis Cote <[EMAIL PROTECTED]> wrote: > > Jonas S

Re: [sqlite] SQL Newbie problem I guess...

2008-03-11 Thread Dennis Cote
Jonas Sandman wrote: > > I must be missing something obvious here... > > I have created my database like this: > > CREATE TABLE Folders (folderid INTEGER PRIMARY KEY, parentid INTEGER, > rootid INTEGER, path VARCHAR(255))"; > > The database is filled with files and folders.. > > folderid paren

Re: [sqlite] SQL Newbie problem I guess...

2008-03-11 Thread BareFeet
Hi Jonas, It seems to me that you only need the path in your query: DELETE FROM Folders WHERE path LIKE 'C:\MP3\Albums\%'; Alternatively you could keep parentid and just the appended path, ie: folderid parentid path 1 0C:\MP3\Albums\ 2 1Abba - Definitive Collect

[sqlite] SQL Newbie problem I guess...

2008-03-11 Thread Jonas Sandman
Hello, I must be missing something obvious here... I have created my database like this: CREATE TABLE Folders (folderid INTEGER PRIMARY KEY, parentid INTEGER, rootid INTEGER, path VARCHAR(255))"; The database is filled with files and folders.. folderid parentid rootid path 1 0 1