conversion of a varchar data type to a datetime data type resulted in an out-of-range value

Ambiguous date formats are interpreted according to the language of the login. This works set dateformat mdy select CAST(’03/28/2011 18:03:40′ AS DATETIME) This doesn’t set dateformat dmy select CAST(’03/28/2011 18:03:40′ AS DATETIME) If you use parameterised queries with the correct datatype you avoid these issues. You can also use the unambiguous “unseparated” format yyyyMMdd hh:mm:ss

Daemon and Service Difference

A daemon is a background, non-interactive program. It is detached from the keyboard and display of any interactive user. The word daemon for denoting a background program is from the Unix culture; it is not universal. A service is a program which responds to requests from other programs over some inter-process communication mechanism (usually over … Read more

Performing a health check in .NET Core Worker Service

Another way of doing this is to implement IHealthCheckPublisher. The benefits of this approach is the ability to re-use your existing IHealthChecks or integration with 3rd party libraries that rely on IHealthCheck interface (like this one). Though you still target Microsoft.NET.Sdk.Web as the SDK you don’t need to add any asp.net specifics. Here is an … Read more

Mongodb service won’t start

After running the repair I was able to start the mongod proccessor but as root, which meant that service mongod start would not work. To repair this issue, I needed to make sure that all the files inside the database folder were owned and grouped to mongod. I did this by the following: Check the … Read more

Start Service from Notification

It is possible to start a service from a notification. You have to use PendingIntent.getService instead of pendingIntent.getActivity. Intent notificationIntent = new Intent(mContext, HandleNotificationClickService.class); PendingIntent pendingIntent = PendingIntent.getService(mContext, 0, notificationIntent, 0); Notification notification = new Notification(icon, tickerText,System.currentTimeMillis()); notification.setLatestEventInfo(mContext,contentTitle , contentText, pendingIntent); notification.flags = Notification.FLAG_AUTO_CANCEL | Notification.FLAG_ONGOING_EVENT; NotificationManager notificationManager = (NotificationManager) mContext.getSystemService(Context.NOTIFICATION_SERVICE); notificationManager.notify(CALLER_ID_NOTIFICATION_ID, notification);

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)