Hi, I have three tables, 1. Table Entity_xdata containing following fields.... |Entity_id|Layer|grpuid|
2. Table, group_xdata_pipe containing following fields .... |grpuid|LNV| 3. Table group_id_vs_reggappname containing following fields .... |grpuid|reggappname| Now, I need to Fire a query to SQlite where in I get the list of all the distinct LNVs. Currently I achieve it by following two query commands as follows .... SELECT DISTINCT Entity_xData.grpuid from Entity_xdata INNER JOIN group_id_vs_regappname ON(Entity_xdata.grpuid = group_id_vs_regappname.grpuid AND group_id_vs_regappname.reg_appname = 'CPD1') I get the grpuids using this command and then i use the grpuids that i get from this query, as an input to my next query, something like this ... SELECT DISTINCT Line_Number_View FROM (SELECT grpuid,line_number_view FROM group_xdata_pipe WHERE grpuid = '%s' ORDER BY grpuid ASC)ORDER BY Line_Number_View ASC",query_result[x]) My question is Is it possible to combine both these querries into one ? or in other words How to Select using Result obtained from other Select statements ? Thanks in Advance, Atul -- View this message in context: http://www.nabble.com/how-to-Select-using-results-from-other-selects-in-a-single-SQlite-querry-statement---tp25149885p25149885.html Sent from the SQLite mailing list archive at Nabble.com. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users