Retrieve data as Json from Sql server

Many a times we need to retrieve JSON from sql server. JSON is a very lightweight data exchange format.It is used in many programming language like C#, java, PHP.That is why it is a ideal data exchange format.It is basically a collection of key and value pair.Is human readable format.In order to retrieve data as JSON from sql server we use for json path.

Example:
SQL server
Angular app
After calling the api, all we need to do is use json.parse
This automatically retrieves us our user and user asset information from SQL server

Have you got a better way to render the same write in the comment section below or do share if you find it exciting.If you stumble upon any problem do comment.Will get back to you.

Comments