How do I only get the 2 latest postings from a table using DBPub. The DBPub makes its own SQL like this - how can I modify/make another?
"select * from [weblogarticle] t1 where t1.[weblogarticledraft] <> true order by t1.[weblogarticledate] desc"
How do I only get the 2 latest postings from a table using DBPub. The DBPub makes its own SQL like this - how can I modify/make another?
"select * from [weblogarticle] t1 where t1.[weblogarticledraft] <> true order by t1.[weblogarticledate] desc"
mfh@haug-it.dk wrote:How do I only get the 2 latest postings from a table using DBPub. The DBPub makes its own SQL like this - how can I modify/make another?
"select * from [weblogarticle] t1 where t1.[weblogarticledraft] <> true order by t1.[weblogarticledate] desc"
On the first tab, Datasource, check the "Use custom sql" check box and specify your own SQL.
Found out - Perfect:
select top 2 weblogarticleid, weblogarticleheadline, weblogarticledescription from weblogarticle where weblogarticledraft <> true order by weblogarticledate desc
You must be logged in to post in the forum