Showing posts with label guys. Show all posts
Showing posts with label guys. Show all posts

Monday, March 19, 2012

Add user to Local Group Error

Guys,

I need help installing SQL Server 2005. I meet all of the pre-req's and setup seems to run normally until it starts installing the services and database engine. I receive the following error:

SQL Server Setup was unable add user NT AUTHORITY\NETWORK SERVICE to local group SQLSERVER2005DTSUser$server.

It repeats the error for for the other groups that are created with SQL install.

Am i missing something that's obvious? I couldn't find anything in the documentation or anywhere else.

Here are a couple of things to try:

1. Check the installation log files, located at %Program Files%\Microsoft SQL Server\90\Setup Bootstrap\LOG\Files for more details on the error.

2. Try to add the service manually to the local groups using the Computer Management Admin tool. Then re-run setup.

Paul

Thursday, March 8, 2012

add record in SQL

hi all, i hope to get some help from u guys. i want to add record to DB but it doesn't work, the record cant be added to db. i've a java clas like below:

public class CustomerDataBean {
private Connection connection;
private PreparedStatement addRecord, getRecords;
private PreparedStatement sqlFind;

// construct CustomerDataBean object
public CustomerDataBean() throws Exception
{
// load the Cloudscape driver
Class.forName( "COM.cloudscape.core.RmiJdbcDriver" );

// connect to the database
connection = DriverManager.getConnection(
"jdbc:rmi:jdbc:cloudscape:customers");

connection.setAutoCommit(false);

sqlFind = connection.prepareStatement(
"SELECT email, password " +
"FROM custinfor " +
"WHERE email = ? AND password = ? " );

getRecords =
connection.prepareStatement(
"SELECT * FROM custinfor"
);

addRecord = connection.prepareStatement(
"INSERT INTO custinfor (email, firstName, lastName, password, verify, address, phone, creditCard ) " +
"VALUES ( ?, ?, ?, ?, ?, ?, ?, ? )" );

}

public void addCustomer( CustomerBean customer ) throws SQLException
{
addRecord.setString( 1, customer.getEmail() );
addRecord.setString( 2, customer.getFirstName() );
addRecord.setString( 3, customer.getLastName() );
addRecord.setString( 4, customer.getPwd() );
addRecord.setString( 5, customer.getVPwd() );
addRecord.setString( 6, customer.getAdd() );
addRecord.setString( 7, customer.getPhone() );
addRecord.setInt( 8, customer.getCC() );

addRecord.executeUpdate();
}

i called addCustomer method at JSP.
thanks.are you sure that the user name in your connection string that you are using has insert permissions to that table.

I know stupid, but I forget to give execute permissions to sp's all the time.