Translate

Tuesday, December 30, 2014

Running vprtmupd.exe To Update Vertex

It took me a while to figure it out. I couldn't find any information on how to run this in the supplied documents. The image below shows how I ran this from the command prompt:



When I tried running this by just executing the exe, the command promt would open and after I entered the path for the data I would get an error saying "Unable to establish a connection with the Payroll Tax Database."

Saturday, December 27, 2014

Fixed Dell Latitude Display Flickering

I was having problems with the external displays that I use with my Dell Latitude E7440. At work they would flicker, and at home one would flicker and the other would stop working after about two hours. I updated the video drivers and BIOS and the problem gone.

Dell makes it easy to update your drivers. Just go to the Dell support web site and you will find all of the latest drivers for your laptop.

Tuesday, November 25, 2014

Dell Laptop Runs Slow When Docked

My Dell 7440 work laptop ran great at work but it was running increasingly slower at home. It finally got to the point where the CPU usage was running at over 90% capacity. When I took the laptop off of the docking station and the CPU dropped to almost 10%. Putting the laptop back on the docking station, the CPU shot back up to over 90%. So I figured there was a problem with the docking station or maybe it couldn't handle the two large displays I had connected to the dock. I did some research on the Internet - a few people stated that they had a problem with the laptop running slow and that the problem was caused by the external power supply. I just happened to have a spare power supply so I swap the supply. Problem solved!

Tuesday, September 9, 2014

Hibernate NamedQueries and NamedNativeQueries Errors

Working on Android client/server project I ran into some problems with Hibernate 4.3.1 annotations and Java code for Named Queries and Native Named Queries. The errors I was receiving were along the lines of "error in named query". Below is an example of the annotations and code that finally worked for me when querying an MSSQL database. Note the differences between the NamedQuery and corresponding NativeNamedQuery.
For a MySQL database the NamedQuery did not work.

The annotations:

@Entity
@Table(name="Member")
@NamedQueries({
@NamedQuery(name="Member.loadByEmail", query="select m from Member m where email= :email"),
@NamedQuery(name="Member.loadByEmailAndPassword", query="select m from Member m where email= :email and password= :pwd")
})
@NamedNativeQueries({
@NamedNativeQuery(name="Member.nLoadByEmail", query="select m.* from Member m where email= :email", resultClass=Member.class),
@NamedNativeQuery(name="Member.nLoadByEmailAndPassword", query="select m.* from Member m where email= :email and password= :pwd", resultClass=Member.class)
})
public class Member implements Serializable{...

The code to create the query:

public Object findMemberByEmail(String email){
  return em.createNamedQuery("Member.LoadByEmail", Member.class).setParameter("email", email).getSingleResult();
}

public Object nFindMemberByEmail(String email){
  return em.createNamedQuery("Member.nLoadByEmail").setParameter("email", email).getSingleResult();
}

Saturday, August 30, 2014

Eclipse Android apk Maven Build Error

Got the "Project build error: Unknown packaging: apk" error. Fixed by adding the extensions option to pom.xml file.

<extensions>true</extensions>
<packaging>apk</packaging>

Thursday, June 5, 2014

Samsung S3 Camera Failed

I tried everything that I found on the Internet to try to fix the problem and for me what finally worked was replacing the camera. It cost me around $19 dollars for a new camera and it was relatively easy to replace.

Wednesday, March 12, 2014

SharePoint - Database Cleanup

From what I've read it seems that one of the common things that can happen when you're working with SharePoint is that you end up with orphaned databases on your SQL server or in SharePoint. Here are some PowerShell commands to help clear that up.
List all databases that are being used by SharePoint:
Get-SPDatabase | Sort-Object disksizerequired -desc | Format-Table Name
Use the returned list to compare with the databases on your SQL server and delete any databases that are not on the list.

List all databases that are being used by SharePoint that are not on the database:
Get-SPDatabase | where {$_.exists -eq $false}
Delete the orphaned databases:
Get-SPDatabase | where {$_.exists -eq $false} | foreach {$_.delete()}

Tuesday, March 11, 2014

SharePoint - Is It SharePoint Search Or FAST Search

If you set up your SharePoint site to use FastSearch and you want to make sure that your SharePoint site is using FAST run the "Get-SPEnterpriseSearchExtendedQueryProperty" PowerShell command. If you have FAST set up correctly you should see something like this:

PS C:\> Get-SPEnterpriseSearchExtendedQueryProperty -SearchApplication "Search Service Application" 
PropertyKey Value ----------- ----- FASTSearchContextProperties SPS-Location,SPS-Responsibility FASTSearchAdminServiceAuthenticationUser comp\svc_spadmin FASTSearchAdminServiceLocation http://intranet.contoso.com:13257 FASTSearchQueryServiceLocation http://intranet.contoso.com:13287 FASTSearchContextCacheTimeout FASTSearchManagedPropertyResultMapping FASTSearchDisableUserContext FASTSearchResourceStoreLocation http://intranet.contoso.com:13255 FASTSearchAlternateAccessMapProperties
A regular SharePoint search setup would show something like this:

PropertyKey                               Value  
-----------                               -----  
FASTSearchContextProperties               SPS-Location,SPS-Responsibility 
FASTSearchAdminServiceAuthenticationUser  
FASTSearchAdminServiceLocation  
FASTSearchQueryServiceLocation  
FASTSearchContextCacheTimeout  
FASTSearchManagedPropertyResultMapping  
FASTSearchDisableUserContext  
FASTSearchResourceStoreLocation  
FASTSearchAlternateAccessMapProperties  

SharePoint - Check Content Source Connection

The Windows PowerShell for Search Server 2010 reference can be found at technet. I was troubleshooting our FAST setup and used the "Ping-SPEnterpriseSearchContentService" to check if I could reach the content source from our SharePoint server.

ping-spenterprisesearchcontentservice -hostname fastsearch.mydomain.local:13391

Here is my result. If you scroll to the right you will see one line for the FASTSeachCert has true for ConnectioSuccess.
CertificateName                      Thumbprint                          ExpiryDate                       ConnectionSuccess
---------------                      ----------                          ----------                       -----------------
No certificate                       No certificate                      None                             False
CN=ForefrontIdentityManager          47FA1E8786C5E940887F10176FEFA88A... 12/31/2039 6:59:59 PM            False
SERIALNUMBER=77961234, CN=Go Dadd... 7C4656C3061F7F4C0D67B319A855F60E... 11/15/2026 8:54:37 PM            False
OU=Go Daddy Class 2 Certification... DE70F4E2116F7FDCE75F9D13012B7E68... 6/29/2024 1:06:20 PM             False
CN=WMSvc-MOSS                        BEE607B03C17EBC1075F7F8708C334B5... 6/25/2020 9:39:36 AM             False
E=info@valicert.com, CN=http://ww... 317A2AD07F2B335EF5A1C34E4B57E8B7... 6/25/2019 8:19:54 PM             False
CN=*.mydomain.org, OU=Domain Con...  370441FEFE89736CA69A611E45B0D7A6... 3/23/2017 5:26:48 PM             False
CN=FASTSearchCert                    2E76CBC921BEF69387E89C9152848AB2... 3/10/2015 11:16:27 AM             True
CN=FASTSearchCert                    443B3C48B3182409E7E2D7906397B175... 11/15/2014 10:57:28 AM           False
CN=FASTSearchCert                    DAD3BBABB12E1F4F309B591761993B71... 11/4/2014 3:02:53 PM             False
CN=mysite.mydomain.org, OU=Domai...  51205810A0700BB6F03A138746B682AF... 3/22/2013 4:05:18 AM             False

Sunday, March 9, 2014

Delete A Service Application In SharePoint

I needed to delete a service application in SharePoint. Tried to delete it using Central Admin and PowerShell and neither one worked. Good old Staadm was able to delete it. Here is the command:

stsadm.exe -o deleteconfigurationobject -id "87349a22-0cd6-4b35-b420-78fa2dff8c26"

You can find the ID of the service application in the address bar of Central Admin:
You can find the ID using PowerShell:

PS C:\Users\argolebiowski> Add-PSSnapin Microsoft.SharePoint.PowerShell
PS C:\Users\argolebiowski> Get-SPServiceInstance -server moss

TypeName                         Status   Id
--------                         ------   --
Managed Metadata Web Service     Online   c0b5f68e-424c-434f-8e06-71960fe6afe6
User Profile Synchronization ... Online   5ffb0768-ec34-4186-bb72-6c28faced877
Business Data Connectivity Se... Online   09549ad7-bc47-491c-9d73-bfb588c1a8c7
Secure Store Service             Online   4a14360b-3fba-4f90-83f9-97e03eded38d
Claims to Windows Token Service  Disabled 2ea5d177-7e5f-4b90-a3cb-8ed5c65d4e3c
Microsoft SharePoint Foundati... Online   fe30e019-4353-4560-9c8c-90584f8161ac
PerformancePoint Service         Online   c1d2e240-7186-446d-8b1a-24e5ecddd02c

Sunday, March 2, 2014

Add Google Play Services to an Eclipse Project

I was setting up the example applications for week 7 of the Coursera Android Class and I needed to install and add Google Play Services two of the examples. The information for setting up the sevices can be found at:
http://developer.android.com/google/play-services/setup.html

Friday, February 28, 2014

SQL - List All Stored Procedures

I needed to get a list of all of the Stored Proceduresin a database. This is the script that I used:

select ROUTINE_NAME as [Name], LAST_ALTERED as [Date Modified], ROUTINE_DEFINITION as Script
from information_schema.routines 
where routine_type = 'PROCEDURE'

Thursday, January 30, 2014

SQL - List Last Database Backup Date

There is one server with a bunch of databases with some being backed up. I needed to see which ones were being backed up.

Here is the script I used:

Select dtb.name as [Database Name], (select max(backup_finish_date) from msdb..backupset 
where type = 'D' and database_name = dtb.name
) AS [Last Database Backup Date] ,
(select max(backup_finish_date) from msdb..backupset 
where type = 'L' and database_name = dtb.name
) AS [Last Log Backup Date] 
FROM
master.dbo.sysdatabases AS dtb

Monday, January 27, 2014

Backup Nexus Tablet

I figured that if I'm going to be using my tablet for testing out applications then I should back it up before I do anything on it. It was easy to do using the Android SDK.
You will also need to get the Nexus device drivers from ASUS.
Once you've download all of this use the Android Debug Bridge to backup your Nexus.

Here are the sites I used for instructions:
Tech Entice
How-To Geek
Transformer Forums
Android Heat
How to install Nexus 7 drivers on Windows

Monday, January 13, 2014

SQL - List All Triggers In A Database

I needed to get a list of all of the triggers in a database. This is the script that I used:

select sysT.name as [Table Name], sysO.name as [Trigger Name], sysM.definition as [Trigger Script] from  sys.tables sysT
inner join sys.objects sysO on sysT.object_id = sysO.parent_object_id
inner join sys.sql_modules sysM on sysO.object_id = sysM.object_id 
where sysO.type ='TR'

Sunday, January 12, 2014

SharePoint 2013 - First Deployment Problems

Set up a SharePoint 2013 server on a Windows 8 virtual machine.
First issue - the VM was set up with dynamic memory allocation. Don't use dynamic memory allocation with a SharePoint VM!

Next issue. You have to run IE as an administrator to go to the SharePoint Central Administration site. If you don't you will get in to the site but you will be missing some functionality such as "Manage services on a server" or you will get "Sorry, this site hasn't been shared with you" messages.

The biggest problem that I had was with the Distributed Cache. Symptoms were: "Cannot start service AppFabricCachingService ..." when executing Start-CacheCluster command. I tried a lot of "solutions" that I found on the web to get the AppFabric Caching Service to start but nothing worked. Finally found the solution to my problem here. Here's what worked for me:
Run PowerShell as an administrator.
Added the SharePoint snap-in to the PowerShell.
Run Remove-SPDistributedCacheServiceInstance on all servers in the farm.
Create a PowerShell file with the following code:

$SPFarm = Get-SPFarm
$cacheClusterName = "SPDistributedCacheCluster_" + $SPFarm.Id.ToString()
$cacheClusterManager = [Microsoft.SharePoint.DistributedCaching.Utilities.SPDistributedCacheClusterInfoManager]::Local
$cacheClusterInfo = $cacheClusterManager.GetSPDistributedCacheClusterInfo($cacheClusterName);
$instanceName ="SPDistributedCacheService Name=AppFabricCachingService"
$serviceInstance = Get-SPServiceInstance | ? {($_.Service.Tostring()) -eq $instanceName -and ($_.Server.Name) -eq $env:computername}
if([System.String]::IsNullOrEmpty($cacheClusterInfo.CacheHostsInfoCollection))
{
#here's the key. we can't provision, unprovision, start, or stop a Cache Service because we still have a Cache Service that have no server attached 
 $serviceInstance.Delete()
Add-SPDistributedCacheServiceInstance
$cacheClusterInfo.CacheHostsInfoCollection 
}

Execute the PowerShell file on all servers using ".\" in front of the name.
Run Add-SPDistributedCacheServiceInstance on all servers.
In Central Administration confirm that the Distributed Cache Service has been started.
If this didn't work, retrace your steps.
See: Manage the Distributed Cache service in SharePoint Server 2013

Thursday, January 2, 2014

Nexus 7 Will Not Start

So, I dropped my Nexus 7. It was in a case, fell maybe 3 feet, and would not start after the fall. I did some research and figured out that it was most likely, and hopefully, caused by a loose battery connector. Following instructions that I found on YouTube, I opened it up and sure enoughh the connector was loose.