I have recently leaped into parametrized queries in SQL. I am now getting a complaint about a date when executing the query 

> 
> The DateTime represented by the string is not supported in calendar System.Globalization.GregorianCalendar.
> 
> 
> 

When I get the query I get the parametrized query string 

```
SELECT * FROM Table WHERE field = @p_param

```

What I need to get in order to debug this is

```
SELECT * FROM Table WHERE field = "2012-03-12 14:09:00"

```

How on earth do I do this? I suspect it is something simple but I just can't see it!

The datetime parameter is being added with the following:

```
sql2.Parameters.Add("@p_UpdateTime", SqlDbType.DateTime).Value = DateTime.Parse(updateTime);

```

and uptime is being set with

```
String updateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ff");

```