Stack Overflow is a community of 4.7 million programmers, just like you, helping each other.

Join them; it only takes a minute:

Sign up
Join the Stack Overflow community to:
  1. Ask programming questions
  2. Answer and help your peers
  3. Get recognized for your expertise

I have a C# .Net desktop application project that requires an sql database wherein instead of using a local database, I am planning to use a cloud hosted sql database until I found out about sql azure. My question is just like the title, I just like to know/clarify/confirm if I can do that?

share|improve this question
up vote 1 down vote accepted

Technically this is not a problem.

SQL Azure gives you a connectionstring, just like any other SQL database.

As long as your client PC can access Azure servers, you are good to go.

This has been well covered here on SO: Is SQL Azure suitable for Desktop client applications

You might want to consider a DAL inbetween, possibly using WCF or something like that, but again that is covered in the above link. This decouples your end users from your database, which is good for all sorts of reasons including versioning and security.

share|improve this answer
    
just like Cronus stated, i think it would be wise to have a DAL in between; so you wont have dependencies just in case something does go wrong – Ramie Jun 10 '13 at 14:49

Yes, this can definitely be done, and I speak from experience of doing so on several different projects that we've undertaken.

Your C# code can certainly access the data held in SQL Azure, but be sure to remember that SQL Azure lives behind a firewall and that you have to allow your IP address to access the service - remember, dynamic IP addresses can change and therefore the firewall rules will need to be updated to reflect this. Ideally, use a static IP address from your ISP to negate this problem.

You can also connect to your SQL Azure database from SQL Server Management Studio too, as SQL Azure provides the connection strings to do so. Just remember that SQL Azure != SQL Server, as there's some minor differences in types and T-SQL, but nothing that can be figured out.

Hope this helps!

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.