0

I am using a database-first approach and I have to call a stored procedure which is selecting records from multiple tables using an inner join.

Here is my stored procedure:

select 
    b.current_year as [Year], b.shortcode, 
    a.uid, a.ccode, accno, name, pname 
from 
    pfemp a 
inner join 
    destination b on a.uid = b.uid 
where 
    a.ccode = @ccode
marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
  • refer https://stackoverflow.com/questions/28599404/how-to-run-stored-procedures-in-entity-framework-core – Ansil F Nov 27 '20 at 12:03
  • [Bad habits to kick : using table aliases like (a, b, c) or (t1, t2, t3)](https://sqlblog.org/2009/10/08/bad-habits-to-kick-using-table-aliases-like-a-b-c-or-t1-t2-t3) – marc_s Nov 27 '20 at 12:04
  • @Ansil F I already knew toh to stored procedure, here my question is how to use stored procedure with joins – RahulSharma Nov 28 '20 at 13:45

0 Answers0