{"id":53,"date":"2012-06-09T11:19:32","date_gmt":"2012-06-09T11:19:32","guid":{"rendered":"http:\/\/www.mahmuttalhakoz.com\/blog\/?p=53"},"modified":"2013-07-01T21:37:29","modified_gmt":"2013-07-01T21:37:29","slug":"c-access-veri-tabani-ile-tarih-sorgulama","status":"publish","type":"post","link":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/2012\/06\/09\/c-access-veri-tabani-ile-tarih-sorgulama\/","title":{"rendered":"C# Access Veri Tabani ile Tarih Sorgulama"},"content":{"rendered":"<p><em><code>SqlCommand cmd = new SlqCommand (\"SELECT * FROM tabloadi WHERE tarih=#\" + dateTimePicker1.Value.ToString(\"yyyy\/MM\/dd\").Replace('.', '\/') + \"#\",MyConnection);<\/code><\/em><br \/>\nDateTimePicker objesinden gelen veriye gore veri tabanimizdan tarih sorgulatmayi bu sekilde yapabiliriz.<\/p>\n<p>Tabii ki tavsiye edilen sekli ve daha basitlestirilmis hali ise parametre kullanilarak yapmaktir. <\/p>\n<p><code><br \/>\nSqlCommand cmd = new SlqCommand (\"SELECT * FROM tabloadi WHERE tarih=@tarih\",MyConnection);<br \/>\ncmd.Parameters.AddWithValue(\"@tarih\", dateTimePicker1.Value.ToString(\"yyyy\/MM\/dd\"));<br \/>\n<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>SqlCommand cmd = new SlqCommand (&#8220;SELECT * FROM tabloadi WHERE tarih=#&#8221; + dateTimePicker1.Value.ToString(&#8220;yyyy\/MM\/dd&#8221;).Replace(&#8216;.&#8217;, &#8216;\/&#8217;) + &#8220;#&#8221;,MyConnection); DateTimePicker objesinden gelen veriye gore veri tabanimizdan tarih sorgulatmayi<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[11,136,135,12,7,10,8,9],"class_list":["post-53","post","type-post","status-publish","format-standard","hentry","category-csharp","tag-c","tag-c-parameters","tag-c-parametre","tag-csharp-2","tag-datetimepicker","tag-sorgulama","tag-tarih","tag-veritabani"],"_links":{"self":[{"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/53"}],"collection":[{"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=53"}],"version-history":[{"count":12,"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/53\/revisions"}],"predecessor-version":[{"id":296,"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/posts\/53\/revisions\/296"}],"wp:attachment":[{"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=53"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=53"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.mahmuttalhakoz.com\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=53"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}