Category Archives: SQL
I had a function in my .NET application, that needed to do a search with an unknown number of parameters. for example: select * from tbl where x=1 or x=2 or x=3 or x=4 Solution: Pass in a comma seperated … Continue reading
Assuming you’re joining on columns with no duplicates, which is by far the most common case: An inner join of A and B gives the result of A intersect B, i.e. the inner part of a venn diagram intersection. An … Continue reading
I’ve run into this problem many many times already. here is a workaround? 1. save the excel as either tab delimited or pipe delimited. (the problem here is that it ads quotes to the import, but thats easily fixable later….) … Continue reading
SELECT 1 AS tag, NULL AS parent, user_id AS [li!1!title], name AS [li!1] FROM t_users FOR xml explicit comes out as: <li title="1">user Name 1 </li> <li title="2">user Name 2 </li> <li title="3">user Name 3 </li> etc.