Database Last Updated Date
I was how can get a database's last updated date??
thanx
View Complete Forum Thread with Replies
Related Forum Messages:
Save Updated Date When Row Is Updated
Hi,I want to save the last modification date when the row is updated. I have a column called "LastModification" in the table, every time the row is update I want to set the value of this column to the current date. So far all I know is that I need to use a trigger and the GetDate() function, but could any body help me with how to set the value of the column to getdate()? thanks for your help.
View Replies !
Last Date Stored Proc Updated???
Is there such a date/time?I see the Created date on the list of stored procs, but really want aDate Last Updated. After changing code for 3 hours, I tend to forgetwhich procs I've worked on, and which need to be move to production.any simple way to keep track of the last procs played with?thanks in advance...Join Bytes!
View Replies !
Finding Last Updated/modified Date
Hi, I am using SQL Server 2000 and have the following questions: 1. How do I know the last updated (data) date using system objects or any other method? 2. How do I know the last modified date of a table using system objects or any other method? 3. How do I know when a table is last accessed Any help is appreciated Thanks for your time and help in advance Kumar
View Replies !
Updating Modified/updated Date Column?
If your tables contain created and modified/updated dates what is the best practice for these? 1. Should you use UTC dates? 2. Do you use a default for the creation date (I assume yes)? 3. Should you create a trigger to handle the last update date? Or do you update the column directly in your stored procedures that modify data? Also, as an aside if you store the user who created/updated the record do you store a foreign key reference to the user table or do you store the username as a varchar? Of course I know you'd normally store the fk, but I wasn't sure if the "logging" nature of the column suggests storing a string value.
View Replies !
Sql Server 2005 And Stored Procedures - Updated Date?
Hi, I was wondering, is it really true that in Sql Server 2005, there is no updated date -property for stored procedures? There is a created date -property, but it's not useful, because stored procedure's get updated often. This is a huge disadvantage for me, and I was really waiting for ms to fix this problem after sql server 2000, but no. Does anyone figured out any solution to this problem? Br, Riika
View Replies !
Linked Reports Not Being Updated When Master Report Is Updated
Since updating to SQL Server 2005 SP2 I've noticed two things about Linked Reports. 1. I do a lot of 'Snapshot' reports. With SP-1 if I updated a master report and made any changes to the Parameter List - it undid all my custom parameter changes on linked versions (restored to the Master Reports Defaults). While this is no longer happening with SP2 - it is still 'unhiding' the parameters. 2. With SP-1 if I added/deleted columns or made other changes to the report structure - the linked reports would pick up on the changes with their next refresh. With SP-2 I'm finding that I have to 'Re-link' the linked report back to the master report before the changes are refreshed. This is very time consuming especially with each report having 8 or more Snapshot reports pre-set up. Am I missing something - or is this a 'bug'... Any help would be appreciated...
View Replies !
Database Is Not Updated
I am trying to insert data to a simple table using SQL express However , I can see the data saved in the DataSet but not in the actual database. If I try to insert the same user again , I got primary key violation ??? Here is the insert function : string SqlConnection = @"Data Source=.SQLEXPRESS;AttachDbFilename=|DataDirectory|QJ.mdf;Integrated Security=True;User Instance=True"; SqlConnection Conn = new SqlConnection(SqlConnection); SqlDataAdapter DataAdapter = new SqlDataAdapter("SELECT * FROM USERS", Conn); SqlCommandBuilder ComandBuilder = new SqlCommandBuilder(DataAdapter); DataAdapter.InsertCommand = ComandBuilder.GetInsertCommand(); DataAdapter.UpdateCommand = ComandBuilder.GetUpdateCommand(); DataSet DS = new DataSet(); DataAdapter.Fill(DS, "USERS"); DataTable DT = DS.Tables["USERS"]; DataRow DR = DT.NewRow(); DR["NAME"] = txtUserName.Text; DR["Password"] = txtPass.Text; DR["Type"] = 1; DT.Rows.Add(DR); DataAdapter.Update(DS,"USERS"); DS.AcceptChanges(); Conn.Close(); I dont know what I have done wrong Please help Thanks very much
View Replies !
An Email Is Sent When The Database Is Updated..any Help?
in the database, there is some information about the applicant: his name, his email, his status (accepted or rejected)....etc. the page that is shown to the administrator displays the applicant name and his status, when he changes any of the applicants status, an email is sent to that applicant. is there any way to do that? thanks in advance
View Replies !
MS SQL Database Doesnt Get Updated
Till yesterday every thing was fine....after i installed visual studio...god knws wat happnd dat it was not working, i did everything again but noe using my asp.net forms i am unable to write/edit/update the database, though i can view the same.....can any one suggest was might b d problem. (i have set permissions for IUSER bot Read and Write)
View Replies !
Can &"Date Modified&" Col Be Automatically Updated W/o Trigger For Each Table?
Hello, I am using SQL Server 2005 and ASP.NET 2.0. We have a very simple content management system where we have to keep track of date last modified for each row in all of our content tables. I know there's a "timestamp" datatype that is used for replication scenarios, but is there anything similar that I can use to set up a date_modified column for each of my content tables that will automatically update with GETDATE() whenever anything in a given row is updated? Or do I have to create a date_modified column of smalldatetime datatype and write a trigger on update for EVERY single table of content that I have in the database? It seems there should be an easier way to do this than to write 20 triggers for my 20 content tables. Thanks!
View Replies !
How To Keep Tables Updated That Are Imported From Other Database
Dear All, I am making web application using Asp.net C#(Visual Studio2005). And Sql server 2000 as a back End. Actually I am fetching data from other database(named as retailexcel but in same server). I have wriiten a view (in retailexcel database) to get required data from four table of other database. My problem is when I fetch those data(about 40000 to 50000 record) It taking to much time. I tried catch feature of asp.net2.0. Time reduced but not significantly. So I am trying to import those tables to my database (named Inventory) from that retailexcel. Now problem is every day or two, record of those tables changes. How can I keep update my tables (which are importing from retailexcel) Please suggest me some idea. Thanks
View Replies !
Need Help To Check When Was Database Last Accessed/updated
I am trying to manage a sql server. In this sql server, I have about 200 databases. Is there any way/suggestions to check to see if some of the database has not been accessed/updated for the last month or longer? I am trying to develop a system to remove the database that's no longer needed. Thank you.
View Replies !
Connection Failure To SQL When Database Updated
Hi, I have very little, to zero, IT configuration knowledge and I am hoping that someone is able to help me out. I am currently writing the SQL scripts and developing the reports in the SQL Server Business Intelligence Development Studio, and then deploying the reports to the server for managers to eventually view. Recently the IT section updated the test database (temp) that is connected to SQL Server 2005, with the live database (production), so that the data and database structure were up to date for me to create the reports. When the update was done, the connection to SQL Server failed, and the newly appointed IT person responsible for SQL does not know how to resolve the problem. Up until yesterday I was getting a message that said that the connection has failed and then today I have the following message (she has been trying very hard to get it working): An error occurred during local report processing. An error has occurred during report processing. Query execution failed for dataset 'Division'. The SELECT permission was denied on the object 'Dim1', database 'payglobal', schema 'dbo'. The reports that were deployed to the server prior to the update are still accessible however I am unable to review any reports I edit within the Development Studio. It has been out of action now for nearly two weeks. Could someone please give me very detailed instructions on where the IT person should look, and what she should do to fix the problem. I will then pass these onto her. Thanks.
View Replies !
How To Find The Last Updated Tables In A Database
Hi, I am trying to create a data dictionary for a huge application which has aroung 300 tables in the database....when i perform any operation in the application some tables are updated.... can you help me to find out how can we find out the last updated tables in the database ??
View Replies !
Database Not Beeing Updated When Debugging PLEASE HELP
Hello I am developing a windows forms app in Visual C# Express edition, it has a database, and when I am debugging, nothing is being done in the database, and I am sure it is nothing to do with the code. Because all I am doing is creating a database with one table, and just dragging the table (with the datagridview) onto a form, then it runs perfectly, but when I add or delete records, and exit the program, it is not reflected on my DB (which is a SQL Server express DB by the way), I was looking everywhere, and all I could find was to change the "copy to output directory" propierty of the DB to "copy if newer" but still it doesn't work, Any ideas why this may be happening?? thanks a lot Andrés
View Replies !
Java Alert When Database Table Updated
Hello Everyone, I am new to connecting to databases through java and in fact have not done much database programming although I am fairly good at SQL. I have used the MS JDBC driver to connect to a MS SQL server database but I want to update my application every time a record is added to the database and or alert the user. From what I have read, i assume that I can create a Trigger in java but how do I get my trigger to call a method / run java code? Thanks for your time and Help Martin.
View Replies !
How To Find Out Date/time When Row Was Updated Last Time
Hello, we need to track date/time of last update for each record in a table. As we understand it, we can't use field type Timestamp as this type does not use dates/times. Is there any SQL function available which we can bind to a column or do we really have to use triggers? Greetings from Mannheim, Germany Ricardo
View Replies !
How To Find Out Date/time When Row Was Updated Last Time
Hello, we need to track date/time of last update for each record in a table. As we understand it, we can't use field type Timestamp as this type does not use dates/times. Is there any SQL function available which we can bind to a column or do we really have to use triggers? Greetings from Mannheim, Germany Ricardo
View Replies !
DataSet Rows Being Deleted, But After The Update , The Sql Database Is Not Updated. The Delete Rows Still In The Database.
Stepping thru the code with the debugger shows the dataset rows being deleted. After executing the code, and getting to the page presentation. Then I stop the debug and start the page creation process again ( Page_Load ). The database still has the original deleted dataset rows. Adding rows works, then updating works fine, but deleting rows, does not seem to work. The dataset is configured to send the DataSet updates to the database. Use the standard wizard to create the dataSet. cDependChildTA.Fill(cDependChildDs._ClientDependentChild, UserId); rowCountDb = cDependChildDs._ClientDependentChild.Count; for (row = 0; row < rowCountDb; row++) { dr_dependentChild = cDependChildDs._ClientDependentChild.Rows[0]; dr_dependentChild.Delete(); //cDependChildDs._ClientDependentChild.Rows.RemoveAt(0); //cDependChildDs._ClientDependentChild.Rows.Remove(0); /* update the Client Process Table Adapter*/ // cDependChildTA.Update(cDependChildDs._ClientDependentChild); // cDependChildTA.Update(cDependChildDs._ClientDependentChild); } /* zero rows in the DataSet at this point */ /* update the Child Table Adapter */ cDependChildTA.Update(cDependChildDs._ClientDependentChild);
View Replies !
SQL 2000 To SQL 2005 Upgrade Error - Database Down - Updated - Help Appreciated
SQL 2000 to SQL 2005 Upgrade Error - Database Down - Help Appreciated I am upgrading a SQL 2000 standard database server to SQL 2005 standard on a windows 2003 server I am logged in as domain admin and started the upgrade as 'sa' The upgrade stops with the error: Service MSSQLSERVICE can not be started. Verify you have sufficient privilages to start system services. The error code is (17185) The error log shows: 2007-01-04 15:59:38.77 Server Authentication mode is MIXED. 2007-01-04 15:59:38.79 Server Microsoft SQL Server 2005 - 9.00.1399.06 (Intel X86) Oct 14 2005 00:33:37 Copyright (c) 1988-2005 Microsoft Corporation Standard Edition on Windows NT 5.2 (Build 3790: Service Pack 1) 2007-01-04 15:59:38.79 Server (c) 2005 Microsoft Corporation. 2007-01-04 15:59:38.79 Server All rights reserved. 2007-01-04 15:59:38.79 Server Server process ID is 4188. 2007-01-04 15:59:38.79 Server Logging SQL Server messages in file 'F:SQLDataMSSQLlogERRORLOG'. 2007-01-04 15:59:38.79 Server This instance of SQL Server last reported using a process ID of 2980 at 1/4/2007 3:56:58 PM (local) 1/4/2007 2:56:58 AM (UTC). This is an informational message only; no user action is required. 2007-01-04 15:59:38.79 Server Registry startup parameters: 2007-01-04 15:59:38.79 Server -d F:SQLDataMSSQLdatamaster.mdf 2007-01-04 15:59:38.79 Server -e F:SQLDataMSSQLlogERRORLOG 2007-01-04 15:59:38.79 Server -l F:SQLDataMSSQLdatamastlog.ldf 2007-01-04 15:59:38.79 Server Command Line Startup Parameters: 2007-01-04 15:59:38.79 Server -s MSSQLSERVER 2007-01-04 15:59:38.79 Server SQL Server is starting at normal priority base (=7). This is an informational message only. No user action is required. 2007-01-04 15:59:38.79 Server Detected 4 CPUs. This is an informational message; no user action is required. 2007-01-04 15:59:38.83 Server Set AWE Enabled to 1 in the configuration parameters to allow use of more memory. 2007-01-04 15:59:39.02 Server Using the static lock allocation specified in the locks configuration option. Allocated 20000 Lock blocks and 20000 Lock Owner blocks per node. This is an informational message only. No user action is required. 2007-01-04 15:59:39.02 Server Multinode configuration: node 0: CPU mask: 0x0000000a Active CPU mask: 0x0000000a. This message provides a description of the NUMA configuration for this computer. This is an informational message only. No user action is required. 2007-01-04 15:59:39.04 Server Multinode configuration: node 1: CPU mask: 0x00000005 Active CPU mask: 0x00000005. This message provides a description of the NUMA configuration for this computer. This is an informational message only. No user action is required. 2007-01-04 15:59:39.04 Server Attempting to initialize Microsoft Distributed Transaction Coordinator (MS DTC). This is an informational message only. No user action is required. 2007-01-04 15:59:41.04 Server Attempting to recover in-doubt distributed transactions involving Microsoft Distributed Transaction Coordinator (MS DTC). This is an informational message only. No user action is required. 2007-01-04 15:59:41.04 Server Database Mirroring Transport is disabled in the endpoint configuration. 2007-01-04 15:59:41.04 spid7s Starting up database 'master'. 2007-01-04 15:59:41.05 spid7s 1 transactions rolled forward in database 'master' (1). This is an informational message only. No user action is required. 2007-01-04 15:59:41.07 spid7s 0 transactions rolled back in database 'master' (1). This is an informational message only. No user action is required. 2007-01-04 15:59:41.07 spid7s Recovery is writing a checkpoint in database 'master' (1). This is an informational message only. No user action is required. 2007-01-04 15:59:41.08 spid7s SQL Trace ID 1 was started by login "sa". 2007-01-04 15:59:41.08 spid7s Starting up database 'mssqlsystemresource'. 2007-01-04 15:59:41.11 spid7s Using 'dbghelp.dll' version '4.0.5' 2007-01-04 15:59:41.11 spid7s ***Stack Dump being sent to F:SQLDataMSSQLLOGSQLDump0035.txt 2007-01-04 15:59:41.11 spid7s SqlDumpExceptionHandler: Process 7 generated fatal exception c0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server is terminating this process. 2007-01-04 15:59:41.11 spid7s * ******************************************************************************* 2007-01-04 15:59:41.11 spid7s * 2007-01-04 15:59:41.11 spid7s * BEGIN STACK DUMP: 2007-01-04 15:59:41.11 spid7s * 01/04/07 15:59:41 spid 7 2007-01-04 15:59:41.11 spid7s * 2007-01-04 15:59:41.11 spid7s * 2007-01-04 15:59:41.11 spid7s * Exception Address = 78144D3A Module(MSVCR80+00014D3A) 2007-01-04 15:59:41.11 spid7s * Exception Code = c0000005 EXCEPTION_ACCESS_VIOLATION 2007-01-04 15:59:41.11 spid7s * Access Violation occurred reading address 0000001E 2007-01-04 15:59:41.11 spid7s * 2007-01-04 15:59:41.11 spid7s * 2007-01-04 15:59:41.11 spid7s * MODULE BASE END SIZE 2007-01-04 15:59:41.11 spid7s * sqlservr 01000000 02BA7FFF 01ba8000 2007-01-04 15:59:41.11 spid7s * ntdll 7C800000 7C8BFFFF 000c0000 2007-01-04 15:59:41.11 spid7s * kernel32 77E40000 77F41FFF 00102000 2007-01-04 15:59:41.11 spid7s * MSVCR80 78130000 781CAFFF 0009b000 2007-01-04 15:59:41.11 spid7s * msvcrt 77BA0000 77BF9FFF 0005a000 2007-01-04 15:59:41.11 spid7s * MSVCP80 7C420000 7C4A6FFF 00087000 2007-01-04 15:59:41.11 spid7s * ADVAPI32 77F50000 77FEBFFF 0009c000 2007-01-04 15:59:41.11 spid7s * RPCRT4 77C50000 77CEEFFF 0009f000 2007-01-04 15:59:41.11 spid7s * USER32 77380000 77411FFF 00092000 2007-01-04 15:59:41.11 spid7s * GDI32 77C00000 77C47FFF 00048000 2007-01-04 15:59:41.11 spid7s * CRYPT32 761B0000 76242FFF 00093000 2007-01-04 15:59:41.11 spid7s * MSASN1 76190000 761A1FFF 00012000 2007-01-04 15:59:41.11 spid7s * Secur32 76F50000 76F62FFF 00013000 2007-01-04 15:59:41.11 spid7s * MSWSOCK 71B20000 71B60FFF 00041000 2007-01-04 15:59:41.11 spid7s * WS2_32 71C00000 71C16FFF 00017000 2007-01-04 15:59:41.11 spid7s * WS2HELP 71BF0000 71BF7FFF 00008000 2007-01-04 15:59:41.11 spid7s * USERENV 76920000 769E3FFF 000c4000 2007-01-04 15:59:41.11 spid7s * opends60 333E0000 333E6FFF 00007000 2007-01-04 15:59:41.11 spid7s * NETAPI32 71C40000 71C97FFF 00058000 2007-01-04 15:59:41.11 spid7s * SHELL32 7C8D0000 7D0D2FFF 00803000 2007-01-04 15:59:41.11 spid7s * SHLWAPI 77DA0000 77DF1FFF 00052000 2007-01-04 15:59:41.11 spid7s * comctl32 77420000 77522FFF 00103000 2007-01-04 15:59:41.11 spid7s * psapi 76B70000 76B7AFFF 0000b000 2007-01-04 15:59:41.11 spid7s * instapi 48060000 48069FFF 0000a000 2007-01-04 15:59:41.11 spid7s * sqlevn70 4F610000 4F7A0FFF 00191000 2007-01-04 15:59:41.11 spid7s * SQLOS 344D0000 344D4FFF 00005000 2007-01-04 15:59:41.11 spid7s * rsaenh 68000000 6802EFFF 0002f000 2007-01-04 15:59:41.11 spid7s * AUTHZ 76C40000 76C53FFF 00014000 2007-01-04 15:59:41.11 spid7s * MSCOREE 61FB0000 61FF4FFF 00045000 2007-01-04 15:59:41.11 spid7s * ole32 77670000 777A3FFF 00134000 2007-01-04 15:59:41.11 spid7s * msv1_0 76C90000 76CB6FFF 00027000 2007-01-04 15:59:41.11 spid7s * iphlpapi 76CF0000 76D09FFF 0001a000 2007-01-04 15:59:41.11 spid7s * kerberos 62220000 62277FFF 00058000 2007-01-04 15:59:41.11 spid7s * cryptdll 766E0000 766EBFFF 0000c000 2007-01-04 15:59:41.11 spid7s * schannel 76750000 76776FFF 00027000 2007-01-04 15:59:41.11 spid7s * COMRES 77010000 770D5FFF 000c6000 2007-01-04 15:59:41.11 spid7s * XOLEHLP 622E0000 622E5FFF 00006000 2007-01-04 15:59:41.11 spid7s * MSDTCPRX 622F0000 62367FFF 00078000 2007-01-04 15:59:41.11 spid7s * msvcp60 780C0000 78120FFF 00061000 2007-01-04 15:59:41.11 spid7s * MTXCLU 62370000 62388FFF 00019000 2007-01-04 15:59:41.11 spid7s * VERSION 77B90000 77B97FFF 00008000 2007-01-04 15:59:41.11 spid7s * WSOCK32 71BB0000 71BB8FFF 00009000 2007-01-04 15:59:41.11 spid7s * OLEAUT32 77D00000 77D8BFFF 0008c000 2007-01-04 15:59:41.11 spid7s * CLUSAPI 62390000 623A1FFF 00012000 2007-01-04 15:59:41.11 spid7s * RESUTILS 623B0000 623C2FFF 00013000 2007-01-04 15:59:41.11 spid7s * DNSAPI 76ED0000 76EF8FFF 00029000 2007-01-04 15:59:41.11 spid7s * winrnr 76F70000 76F76FFF 00007000 2007-01-04 15:59:41.11 spid7s * WLDAP32 76F10000 76F3DFFF 0002e000 2007-01-04 15:59:41.11 spid7s * rasadhlp 76F80000 76F84FFF 00005000 2007-01-04 15:59:41.11 spid7s * security 62800000 62803FFF 00004000 2007-01-04 15:59:41.11 spid7s * dbghelp 671B0000 672C7FFF 00118000 2007-01-04 15:59:41.11 spid7s * 2007-01-04 15:59:41.11 spid7s * Edi: 62FA0040: 62FA0028 671AFFF0 00000000 00000000 00000000 00000000 2007-01-04 15:59:41.11 spid7s * Esi: 0000001E: 2007-01-04 15:59:41.11 spid7s * Eax: 0416C05E: C0400096 C0400416 00000416 000062FA 00000000 00000000 2007-01-04 15:59:41.11 spid7s * Ebx: 0416C040: 0105F270 00002000 00000005 00000000 3368C1E0 00000000 2007-01-04 15:59:41.11 spid7s * Ecx: 0105B010: 458B0046 01F88348 00D3850F 458B0000 89C23B50 0F342444 2007-01-04 15:59:41.11 spid7s * Edx: 00000000: 2007-01-04 15:59:41.11 spid7s * Eip: 78144D3A: 24FFA5F3 144E5495 C78B9078 000003BA 04E98300 E0830C72 2007-01-04 15:59:41.11 spid7s * Ebp: 33D6E770: 33D6E790 01C65B97 62FA0040 0000001E 0416C040 0416C6DC 2007-01-04 15:59:41.11 spid7s * SegCs: 0000001B: 2007-01-04 15:59:41.11 spid7s * EFlags: 00010212: 0020006D 00690046 0065006C 005C0073 006F0043 006D006D 2007-01-04 15:59:41.11 spid7s * Esp: 33D6E768: 62FA0040 33D6E7A4 33D6E790 01C65B97 62FA0040 0000001E 2007-01-04 15:59:41.11 spid7s * SegSs: 00000023: 2007-01-04 15:59:41.11 spid7s * ******************************************************************************* 2007-01-04 15:59:41.11 spid7s * ------------------------------------------------------------------------------- 2007-01-04 15:59:41.11 spid7s * Short Stack Dump 2007-01-04 15:59:41.13 spid7s 78144D3A Module(MSVCR80+00014D3A) 2007-01-04 15:59:41.13 spid7s 01C65B97 Module(sqlservr+00C65B97) 2007-01-04 15:59:41.13 spid7s 01CA43B5 Module(sqlservr+00CA43B5) 2007-01-04 15:59:41.13 spid7s 01CA452E Module(sqlservr+00CA452E) 2007-01-04 15:59:41.13 spid7s 0217D3BD Module(sqlservr+0117D3BD) 2007-01-04 15:59:41.13 spid7s 0217B896 Module(sqlservr+0117B896) 2007-01-04 15:59:41.13 spid7s 0100889F Module(sqlservr+0000889F) 2007-01-04 15:59:41.13 spid7s 010089C5 Module(sqlservr+000089C5) 2007-01-04 15:59:41.13 spid7s 010086E7 Module(sqlservr+000086E7) 2007-01-04 15:59:41.13 spid7s 010D764A Module(sqlservr+000D764A) 2007-01-04 15:59:41.13 spid7s 010D7B71 Module(sqlservr+000D7B71) 2007-01-04 15:59:41.13 spid7s 010D746E Module(sqlservr+000D746E) 2007-01-04 15:59:41.13 spid7s 010D83F0 Module(sqlservr+000D83F0) 2007-01-04 15:59:41.13 spid7s 781329AA Module(MSVCR80+000029AA) 2007-01-04 15:59:41.13 spid7s 78132A36 Module(MSVCR80+00002A36) 2007-01-04 15:59:41.13 spid7s Stack Signature for the dump is 0x2BEDE9E0 2007-01-04 15:59:41.27 spid7s External dump process return code 0x20000001. External dump process returned no errors. 2007-01-04 15:59:41.27 spid7s Error: 17185, Severity: 16, State: 1. 2007-01-04 15:59:41.27 spid7s Unable to update password policy. 2007-01-04 15:59:41.27 spid7s SQL Trace was stopped due to server shutdown. Trace ID = '1'. This is an informational message only; no user action is required. Any clues? Cheers Paul
View Replies !
Ensuring Database Is Updated In Mobile Device When Performing Merging
Hi, I am using web service to synchronize data between SQL Server 2005 on a desktop and a SQL Server Mobile Edition on a mobile device. Initially, when i added the data source to my mobile application, my .sdf only has 3 records. I am then supposed to retrieve 97 more records from the desktop server when my mobile application runs. After performing merging, I clicked (on my device emulator) on the .sdf deployed under my mobile application and the query analyzer showed all 100 records. Does this mean my mobile database has been successfully updated with all 100 records? If not, how do I check that? The reason why I am asking this is that the file size of this .sdf with 100 records is still the same as the initial .sdf with only 3 records. How is this possible? Am I missing anything or getting some concepts wrong? Please enlighten. Thanks.
View Replies !
Import Flat Text File String Date To Database Date
I asked this question below, but the answer was that the conversion will take place automatically, but I can't get that to happen. I have a flat file with an 8 position field that I identify as string (and I also tried date) that is yyyymmdd and it needs to go into the database field that is datetime format. IS there something I am doing wrong with the definition of it, or do I need to add some kind of conversion, and if so, what and how would that be done. I'm a dts Sql2000 expert, but the SSIS thing is driving me crazy. I have a ton of dts' to convert and the migration tool doesn't work because there are a lot of active X scripts in them. thanks for your help. Boston Rose
View Replies !
How To Handle A Start Date And End Date.. In A Database..
hi, I am getting a data in a dbf file and they have a StartDate and end Date for where the Statments are valid for.. How can i incorporate them into the database.. right now We are doing with PeriodId.. like while the user imports the data they select which period they want to import the data into.. But now if i have to get those details from the Database how do i store it in the Database..and i need to store them in multiple tables.. Thanks Karen
View Replies !
Date Returned Is Prior To Date In Database
would someone be able to shed some light as to why the date returned to my windows application does not match the date that is actually stored in the database. the products_soldDate field is assigned 1/1/1900 at the product records creation time and is updated when it's sold. when the windows application received that data and I check for it I get the following value 12/31/1899 11:00:00 PManyone has a clue as to what is happening here. It worked fine when I hosted it on a MS SQL 2000 database I just recently moved the data over to a SQL 2005 database
View Replies !
Updating Database Date Field Results In Date Value Of &"01/01/1900&"
Brand new to this, so please bear with me.I'm using the following code fragment to update a datetime field on a SQL Server 2005 database table:cmd.CommandText = "Update Projects Set EntryDate = " & Convert.ToDateTime(txtEntryDate.Text)cmd.ExecuteNonQuery()The result of the update operation is the the database field contains the value "1900-01-01 00:00:00:000". This probably means that I passed nulls to SQL; however, I see a valid date in the txtEntryDate field on my web form (i.e., "06/18/2007"). I also did a "Response.write" to display the txtEntryDate and it looks Okay.Can someone tell me what I'm doing wrong?Thanks!Using Visual Web Developer 2005 Express.
View Replies !
Date In A Database
dear experst: i have a web site and a calendar where a client can select a day week or a month to see some statistics, for the day i know how to do it. and i have also stored procedures. what i want is how to store the startday and end day in a variable when the client select a week or a month, so i can assign these variables to the stored procedure so the stored procedure can query the database and return the data for just the specific selected date. this problem is realy annoying me and i can not continue my work without solving it. any help will be more than appreciated. thanks
View Replies !
Insert Date Into SQL Database
This is a simple n00b question, but how can I insert the current date time into a datetime field in a database when submitting a form? I'm using the SQL DataSource control to do the inserting: <asp:SqlDataSource ID="SqlDataSourceMiguel" runat="server" ConnectionString="<%$ ConnectionStrings:SQLDataConnectionToInsertMiguelsTips %>" InsertCommand="INSERT INTO tblMig(TipTitle, TipBody, TipExcerpt,TipDate) VALUES (@Title,@Body,@Excerpt,@varDate)"> <InsertParameters><asp:ControlParameter ControlID="ctl00$ContentPlaceHolder3$txtTitle" Name="Title" PropertyName="Text" /><asp:ControlParameter ControlID="ctl00$ContentPlaceHolder3$txtBody" Name="Body" PropertyName="Text" /><asp:ControlParameter ControlID="ctl00$ContentPlaceHolder3$txtExcerpt" Name="Excerpt" PropertyName="Text" /><asp:ControlParameter ControlID="ctl00$ContentPlaceHolder3$txtDateNow" Name="varDate" /></InsertParameters></asp:SqlDataSource> Thank You
View Replies !
Sync Date Between Two Database
hi. I have two database( one on local system and another on my host ) there are same in table and stored procedure. i just want to sync data between there in my application ( ...on button on click event ! ). please help me to do it. tnx
View Replies !
Insert Date Into Database
I am trying to insert the current date into my database here is the code I am using sql = "Insert into tblguestbook(date, name, city, state, email, Url, Comments)Values ('" sql = sql & Request.Form(Now) & "','" sql = sql & Request.Form("nametxt") & "','" sql = sql & Request.Form("citytxt") & "','" sql = sql & Request.Form("statetxt") & "','" sql = sql & Request.Form("emailtxt") & "','" sql = sql & Request.Form("urltxt") & "','" sql = sql & Request.Form("commentstxt") & "');" When I review my table the only date that will go into it is 1/1/1900. Please help
View Replies !
Determine Date Database Was Last Used ?
Hi There I am trying to establish the date a database was last used. At first i checked out sp_helpfile and sysfiles to see if there was a date last modified, i also tried using xp_cmdshell to check the date on the actual .mdf or .ldf on the o/s but if the file has not grown the date will be the create date. I need to establish the date a database was last used, either the last time someone logged into it or the last time any sort of command was run against the database, i cannot use sysprocesses as there are no connections to the database, so i need to determine the last time there actually were any processes run against this database. And i need to use tsql, checking audit logs etc is not viable, can anyone help ? Thanx
View Replies !
How To Tell If A Row Is Updated
Hi Im doing a simple update in my SP: update users set Name = @Name where id=@userID and password=@password i want to know if a row gets updated. for example if the userID and password dont match then the row will not get updated.so i want some way to tell if a row has been updated. how do i do this?thanks
View Replies !
Updated
Thanks i just re tested again i think i had the database selected on the wrong one and was getting incorrect results. Seems to be working just as i thought. Snapshot got record 1 here then if udpate to 2 then this does not update the 1 to 2 Cheers
View Replies !
Database Query Won't Use Current Date
Hi, I've just started using SQL Server Express with VWDE 2005 and I have a database with one table called EVENTS which has a datetime column called DATE. I want to select records where the DATE value is in the next two months.First I tried selecting records where the DATE value is >= today. I used the query builder to produce... SELECT [Date], [Title] FROM [Events] WHERE [Date] >= GETDATE()but got the error "Undefined function 'GETDATE' in expression".Am I missing something obvious?
View Replies !
How To Get The System Date And Time Into Database
Hi, I m using ASP.NET with C#. I m having one field which should store the datetime of the system. The datetime should be automatically stored for that entry when the user submits that record on the click event.Then it should display the date time on the gridview from database.I m using sqlserver 2005 and i have created the stored procedure for the insert command.This is the sample sp what should be written here to insert system date time automatically when the user submits the asp.net form ?Is there any code for writing directly in stored procedure or asp.net coding page... ALTER PROCEDURE [dbo].[StoredProcedure1]@salesid INT OUTPUT,@salesdate datetime,@customername varchar(20)ASBEGINSET NOCOUNT ONBEGIN INSERT INTO sales (customername) VALUES (@customername) SELECT @companyid = SCOPE_IDENTITY()END SET NOCOUNT OFFEND Thanxs in advance...
View Replies !
Store Date In Sql Database Using Storedprocedure-help
hi,friends i need your help. i want to store a date into sqlserver database using stored procedure. when i run app. it will give this error....... ---------------------------------- Server Error in '/aspnet/espms' Application. -------------------------------------------------------------------------------- String was not recognized as a valid DateTime. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.FormatException: String was not recognized as a valid DateTime. Source Error: Line 349: cmd.Parameters(6).Value = CType(ddldeltype.SelectedValue, Integer) Line 350: cmd.Parameters(7).Value = txtshipnm.Text Line 351: If cmd.ExecuteNonQuery Then Line 352: add = True Line 353: Else Source File: c:inetpubwwwrootaspnetespmsprchspur_det_add.aspx.vb Line: 351 ------------------------------ my source code is ..... --------------------------------------- - - - - - - - - cmd.CommandText = "add_v_dispatch_det" cmd.Connection = conn cmd.CommandType = CommandType.StoredProcedure cmdbld.DeriveParameters(cmd) cmd.Parameters(1).Value = prid cmd.Parameters(2).Value = cd(1) cmd.Parameters(3).Value = cd(3) cmd.Parameters(4).Value = txtdeldt.text '(dd/MM/yyyy) i.e. "20/12/2005" cmd.Parameters(5).Value = txtrecdt.text '(dd/MM/yyyy) i.e. "20/12/2005" cmd.Parameters(6).Value =CType(ddldeltype.SelectedValue, Integer) cmd.Parameters(7).Value =CType(ddldeltype.SelectedValue, Integer) - - - - - - - - my stored procedure is ... ------------ CREATE PROCEDURE add_v_dispatch_det @purid char(8), @prcd char(20), @qty varchar(5), @deldt datetime, @recdt datetime, @deltype int, @shipnm char(50) AS insert into vend_dispatch_detail values( @purid, @prcd, @qty, @deldt, @recdt, @deltype, @shipnm ) GO -------- what should i do? plz give any solution. thanks in advance. it's urgent
View Replies !
Passing A Date Name To A Database Back Up
I am trying to pass a datename in to a database backup. The date is to be retrieved from the 'monthname' column which is stored in the 'tblbill' table. I have included my ridiculous bit of code below (which funnily enough does not work!!) just so that you can see what I am trying to do. Can anyone help? DECLARE @name varchar(10) backup database Bill to Disk ='c:@name.dat' with init @name =select distinct monthname from tblbill where monthname is not null cheers, Dennis
View Replies !
|