PostgreSQL database call

  • Thread starter Thread starter Mark
  • Start date Start date
M

Mark

I would love to see a snippet of .NET code that either:
1. Executes a raw SQL statement against MySQL or PostgreSql.
2. Executes a stored procedure on PostgreSql.

Ideally both examples would require a parameter ... for example, a select
statement with a where clause that has a changing parameter value - not hard
coded. in sql server, a stored procedure like this would be ...

create proc blah
@person_id int
as

select * from sometable where person_id = @person_id
go

But again, I'm not intersted in the SQL itself - I want to see the .NET code
that calls similar SQL/stored procedure code on MySQL or PostgreSql.

Thanks in advance!

Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top