MSDN has great documentation about Failover Clusters, including a handy checklist for implementing cluster roles, such as:
Preferred:
String x = JComboBox.getSelectedItem().toString();
or
String x = String.valueOf(JComboBox.getSelectedItem());
The second method protects against null values as well.
Avoid using casting:
String x = (String)JComboBox.getSelectedItem();
This would work fine if the item is indeed a string, but will fail if it can (also) be any other data type. To be safe, use either of the first two methods.
If, when attempting to start SQL Server instance, you get an error 1814, this means there's a problem with the tempdb database. Either it can't be created because the disk or volume is not accessible for writing (i.e. a security permission problem), or the volume on which the tempdb resides does not have enough space available. If the latter is the problem, you'll need at least 2 MB of free space for tempdb to be created.
Cisco AnyConnect VPN client may fail on Windows 7 for no apparent reason with the following error:
A possible reason may be that Internet Connection Sharing has been enabled on one or more network interfaces (e.g. used for making a hotspot out of your laptop). Try disabling ICS, then try connecting again.
You can retrieve a list of stored procedures in a SQL Server database through T-SQL by querying the built-in information_schema partition.
SELECT * FROM db_name.information_schema.routines WHERE routine_type = 'PROCEDURE'
Replace db_name with the name of the database you wish to retrieve the list of stored procedures. You can adjust the WHERE-clause even more to get a more narrow list.
You can also do this with the master database which will return all (system and non-system) stored procedures.
You can hide user accounts from the Windows Welcome (log on) screen through the registry. This works with Vista and all later versions.
This is a Perl script I wrote and used for the migration of a linux DHCP server (running dhcpd to a Windows DHCP server. The script looks in the dhcpd.conf configuration file for fixed reservations and exports these to a CSV for processing and importing in another server.
Usage is simple, as it takes its input from STDIN and outputs to STDOUT.
cat /etc/dhcpd.conf | perl export-dhcpd-reservations.pl > output.csv
The script is very simple and can probably do with a lot of improvements, but it's a start for anyone willing to develop it further. It is licensed as GPLv3.
Probably MSSQL 101, but this is how to quickly retrieve the structure of a table:
EXEC sp_help tbl_name GO
tbl_name is the name of the table.
If you accidentally have misplaced or forgotten your Bitlocker Recovery key, but still have access to the system (with an elevated account), you can retrieve the recovery key quite easily through the command line:
Open an elevated command prompt and type:
manage-bde -protectors -get C:
Replace C: with any drive that has Bitlocker enabled. Note that if it's not the system volume but some other drive that's encrypted, you need to unlock it first before you can retrieve the recovery key.
« ‹ | December 2024 | › » | ||||
Sun | Mon | Tue | Wed | Thu | Fri | Sat |
1 | 2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | 16 | 17 | 18 | 19 | 20 | 21 |
22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 |