Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at

  • Fabio Blardone 79 posts 98 karma points
    Jul 29, 2011 @ 12:13
    Fabio Blardone

    Join with SqlHelper


    what's the syntax for join two tables in sqlhelper?


  • Rich Green 2246 posts 3966 karma points
    Jul 29, 2011 @ 14:03
    Rich Green

    Hey Fabio,

    Not sure what you mean? The table joins are done via the SQL.


  • Fabio Blardone 79 posts 98 karma points
    Jul 29, 2011 @ 14:56
    Fabio Blardone

    Sorry, perhaps I expressed myself badly.

    I need to execute a reader via sql helper. But i need the data of two tables.

    I used :

    "select * from Table1,Table2 where = @id and Table1.foreign = "

    but not work.

  • Luke Johnson 61 posts 80 karma points
    Nov 10, 2011 @ 17:00
    Luke Johnson

    In regular XSLT, this works if you have a .NET extension set up:

            <xsl:variable name="name_of_string" select="SQL:GetDataSet('Your-Database-Name',
                    'SELECT columns, from, both, tables, separated, by, commas
                    FROM Table1
                    INNER JOIN Table2
                    ON =
                    WHERE (set whatever conditions here)
    ', 'name_of_string')"

    Then call your column names in xsl:value-of statements to access the XML data. Eg, <xsl:value-of select = "columns" />

    I haven't used SQL Helper, so I'm sorry if this is irrelevant. But this solution works without SQL Helper.

Please Sign in or register to post replies

Write your reply to: