I got the SQL Azure Service up and running. It is running of the hosted server MyCloud Service While working on this app, I found some interesting things. Here is a short summary 1. select * from sys.objects IS YOUR NEW OBJECT BROWSER 2. truncate table tablename will not work in SQL Azure - yes,drop and delete does work. 3. select @@servername will not work but select @@version does work 4. DO NOT TRY exec sp_help and exec sp_who – it will not work 5.Insert WILL NOT WORK if you forget to add a primary key on your table - For example create table test ( my_id int, my_name varchar(10) ) insert into test values (1,'abhi') and you will get an error –“ Heaps can not be replicated tables. Please create a clustered index for the table.” . Just add a PK on my_id and things will work as expected 6. Migrating data from your local DB to the cloud is not easy - check out http://www.stephenforte.net 7. Copy connection string from your https://sql.azure.com/ServerInfo.aspx page - this is the easiest and fastest way to connect your app with SQL Azure abhi Zimbatech Solutions
abhigad
Posts
-
SQL AZURE Service -
Must have 10+ years of experience in .NET 4.0, Visual Studio 10While searching for a job on Dice, I found this requirement. I am strong believer in presenting the truth and not cooking up the resume [we all are] - but when you see something like this, you just have to take a break and laugh for a while...10+ years of experience in .NET 4.0 + VS 2010 - a product that is still in Beta...and then they complain about candidates cooking up their resume... Here is the original job posting
-
Distributed Computing SpecialMicrosoft Architecture Journal has just published its 17th issue. This issue is focused on Distributed Computing. Eight good articles on distributed computing are included in this issue. A pdf copy of this journal is available at http://www.msarchitecturejournal.com/pdf/Journal17.pdf[^]
-
Array Rearrangement trick [modified]Let’s say we have an array of integers
int[] myArray = new int[] {1,2,3,4,5};
So the length of this array is 4 [i.e. n=4] since C# array index starts at 0 Yes the length will be 5 and not 4 as pointed out in the next post. Its my bad - Sorry! Define integer k such that 0<= k < n [n = length of an array] For example, If k = 2 then the output should be {3,4,5,1,2} i.e starting from kth position move all the array elements to the top of an array. If k = 3, output would be {4,5,1,2,3} Here is the challenge. Yes this is trivial if we write a loop that starts at 0 and goes up to n likefor(int i =0;i<n;i++){}
We want to optimize this loop so that it would not loop till n-1. anything less than n-1 is a good solution. [Tip: if you want to reverse this array like 5,4,3,2,1 – you can use the loop likefor(int i=0;i<n/2;i++)
modified on Wednesday, October 1, 2008 5:23 PM
-
VS 2008 Debugger going crazy?Two things The code sample in this explanation [i.e.
public class X
] is not showing the same behavior. Don’t think it is because of the singleton. In fact, same behavior is visible in other scenarios. Accepted, it is doing some sort of circular referencing. Question is why and where? Anyways, the article on singleton is very good. -
VS 2008 Debugger going crazy?Look at the simple code below
using System;
namespace Pattern
{
class Program
{
static void Main(string[] args)
{
Singleton s1, s2;s1 = Singleton.getSingletonInstance(); s1.instanceCount = 100; s2 = Singleton.getSingletonInstance(); } } sealed class Singleton { private static Singleton \_s = null; public int instanceCount; private Singleton() { //do nothing } public static Singleton getSingletonInstance() { if (\_s == null) { \_s = new Singleton(); } return \_s; } }
}
Put the breakpoint on line
if (_s == null)
and then observe the behavior when we do something likes2 = Singleton.getSingletonInstance();
When the breakpoint will hit, try watching the value of _s. The watch window will pop endlessly all over the screen when you click on the following + sign next to the static members icon. Screenshot : http://bp1.blogger.com/_J8sDhLDCDXA/SHv7z5Sx0RI/AAAAAAAAAIA/8xubz88GBJM/s1600-h/debugger.JPG Any clue why? -
Open source project needs some helpWell, the code is still in 1.1 and has not been updated since. Whoever was maintaining this code wrote the message on milling list that s/he don’t want to continue and would be giving up the development. Anyways, we want to find out if there is any point / interest in porting CURL over to .NET 3.5? There are many .c and .h files in this project. Not sure about the value preposition. Thanks!
-
Open source project needs some helpWhat is CURL? CURL Tony G wrote the following message on libcurl mailing list. "The libcurl.NET project at a href="http://sourceforge.net/projects/libcurl-net looks like it was a one-shot back in 2005 and hasn't been updated since. It was built as a bundle with other libraries commonly used with cURL, like OpenSSH. I've had it on my system for a long time, never used, and lack the skill and time to rebuild it with current libs. It looks heavily customized and might be scrap at this point.... I don't think I've seen any inquiries about cURL and .NET for a very long time here. So is this notion of a .NET binding dead? TIA" If you want to help, please download the source code from the CURL @sourceforge. It is a .NET 1.1 project - can be upgraded to 2.0 / 3.5. I am evaluating the source code. Let me know if anybody is interested / thinks there is any point in reviving this project? Chau!
-
Protocol Buffers: Google's Data Interchange Format [modified]Check this out protocol buffer XML is used all over the map, from data integration project to the omnipresent web services. And every time we work with XML, discussion on performance and size overhead is guaranteed. Is there anything better than XML? Is it a protocol buffer? As per the Google documentation, protocol buffer is not a replacement for XML. Open Source at Google has done a good job in releasing the protocol buffer documentation. They do have a java tutorial on the open source website. Let us know your take on this data format?
modified on Wednesday, July 9, 2008 2:41 PM