Microsoft
Software
Hardware
Network
Question : SQL Query
Hei guys,
i have an sql query
SELECT IDENT_CURRENT('Products') + IDENT_INCR('Products');
i want to get the next increment on a table but it returns 2 if they is no values entered,
it does work fine if they is information enter in the table, but does not return 1 if the table is empty,
how can i return 1 if the next increment is 1?
Answer : SQL Query
HERE YOU GO...
SELECT ISNULL(IDENT_CURRENT('Prod
ucts') ,0) +1
Random Solutions
Windows Server 2008 R2: missing start menu of installed applications
Exporting from SQL Server 2005 Table to Flat file with UTF-8 Problem.
get 550 5.7.1. Unable to relay for specific domains....
Table Design
Exchange Server 2007 SP3 with Windows 2008 R2
Exchange 2010 RPC error
Hosts file resolution does not work
Removing a tidserv backdoor rootkit on XP
Simulate Lan over internet
Transit Vlan