I do have my program running in a network. I have set one main computer as server and installed database system too. My other clients create transaction and saves it to database. Now I need to add date and time of server too in that record
Share
If your application is running on the server, you can get the local time through the
DateTime.Nowproperty.If your application is only running on the client and you have no server-side application, only the database, you can include
CURRENT_TIMESTAMPor theGETDATE()function to you SQL statement. (Assuming you’re running SQL Server).