Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. LINQ
  4. ASP.NET Executing Stored Procedure Using LINQ

ASP.NET Executing Stored Procedure Using LINQ

Scheduled Pinned Locked Moved LINQ
csharpdatabaseasp-netlinqxml
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    Vijay Jadhav India
    wrote on last edited by
    #1

    Hi Experts, I have Query as : SELECT StudentID, AcademicDetails, FirstName as "PersonalDetails/FirstName", MiddleName as "PersonalDetails/MiddleName", LastName as "PersonalDetails/LastName" FROM tb_M_StudentInfo WHERE FirstName = 'sarang' FOR XML PATH('Student'), ROOT('Sis'), ELEMENTS XSINIL Which returns Xml output as :

    <Sis xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <Student>
    <StudentID>1</StudentID>
    <AcademicDetails>MCA</AcademicDetails>
    <PersonalDetails>
    <FirstName>Sarang</FirstName>
    <MiddleName>Bal</MiddleName>
    <LastName>Patil</LastName>
    </PersonalDetails>
    </Student>
    </Sis>

    How do I return above Xml from Stored Procedure Using LINQ. Sample code would be greatly appreciated! Thanks.

    Vijay Jadhav.

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups