Replies To: SQLite get "deeper" image

Re: SQLite get "deeper" image

Posted 18 November 2013 - 01:49 AM

You can't achieve this with SQLite queries alone. What you need is to is do a recursive search, which is not something SQLite supports. Other databases, like MSSQL and Oracle, can achieve this, but the feature is fairly advanced; far beyond the level of SQLite. Even MySQL doesn't support it.

As it stands, to do this with SQLite, you'll need to leverage whatever programming language you are using with SQLite and do the search from there. Have it recursively load all the categories, then execute a query that finds all products for those categories, and return a random one.