From: Mogens Melander Date: November 14 2012 8:23am Subject: Dynamic crosstab got me lost. List-Archive: http://lists.mysql.com/mysql/228615 Message-Id: <13421.31302f82.1352881386.nsm@mail.fumlersoft.dk> MIME-Version: 1.0 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: 8bit Guru's I've been tasked with creating a report with information about which images are related to each active article. The images are descriptive icons visualizing different properties. Articles can be active 'on' or not '', and only active is to be included in the result. The number of available icons changes constantly, and are too many, to use anything static. What I got is: Table: main ----------------- code (int) active (on/off) ----------------- Table: icon ----------------- id (int) filename (char) ----------------- Table: iconrel ----------------- code (int) icon (int) ----------------- What I need is something like: code filename1 filename2 filename3 filenameN 1111 on off off on Hopefully somebody out there got more of a clue than I do. Any ideas, anybody? -- Mogens Melander +66 8701 33224 -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.