run query on field name

#1
[eluser]piyush138[/eluser]
Hi,

earlier i was using this statement to retrive all the records form the database

$records = Doctrine::getTable('user_pdf_records')->findAll();

but now i want to retrive the records on field name condition.

note: the field is not auto increamented,and the name of field is user_id

Thanks in advance.

#2
[eluser]Johan André[/eluser]
This is not a CI question... Read the Doctrine documentation?

#3
[eluser]piyush138[/eluser]
here is the correct answer:

$records = Doctrine::getTable('table_name')->findByFieldName($value);

Thanks


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme ¬© 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.