• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
Sheriffs:
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
Bartenders:
  • Mike London

PdqDaoSupport Examples on querying the data

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Team,

Good Morning,

I'm new to Spring PdqDaoSupport API(org.springmodules.purequery.support.PdqDaoSupport) and I'm trying to look for the syntax to execute the below query.How to pass values dynamically need some help on retrieving the data from the tables.Does the TABLE to POJO mapping happens internally ? Spring will take care of that and Please suggest me some tutorials or links which contains some examples.
I tried searching online but i'm not able to find any thing with PdqDaoSupport. Probably I'm not sure whether i'm searching in the right way or not.Thanks a lot...


import org.springmodules.purequery.support.PdqDaoSupport;

public class AccountDao extends PdqDaoSupport {

/*
* Developer will write code here
*/

public Account[] getAccounts() {
String sql = "SELECT * FROM ACCOUNT where ACCOUNTCREATIONDT < ?";
return (Account[]) getPdqTemplate().queryArray(sql,
Account.class);
}

// Other methods goes here

}

Regards,
Venkat-
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic