We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now

x

SQL Server Problem

rajamali
rajamali asked
on
Medium Priority
493 Views
Last Modified: 2011-10-03
hi,below given is the process for creating an server of a3.i just wanted to wanted to know how to create the odbc dsn as given below...plz help me out.......waiting for reply...i will be helpful if u guide me frm starting as im newbie


Setup Guide

Creating the SQL Databases -

Look in the Part3SQL Directory for the Files.

Files - SQL DB Name

db.sql - ASD
A3ItemEvent.txt - A3Itemevent
A3HSDB.txt - HSDB
Friend24.txt - FriendDB


Create the SQL Logins

Create a new user

Login = Whatever you set in your config files.
Password = Whatever you set in your config files.


Creating the ODBC DSN's -
This is an odbc.reg file with the correct information for creating the ODBC DSN's
Quote:
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI]

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3Friend ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="FriendDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3RcvRes ult]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="A3ItemEvent"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3Serial List]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="A3ItemEvent"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\EventA3]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\FriendDB ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="HSDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\HSDB]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="HSDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\LETTERDB ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="FriendDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\LocalSer ver]
"Description"=""
"Server"="(Local)"
"Trusted_connection"=""
"UseProcForPrepare"="Yes"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\Login202 ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\NEWASD]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ODBC Data Sources]
"LocalServer"="SQL Server"
"A3RcvResult"="SQL Server"
"A3SerialList"="SQL Server"
"FriendDB"="SQL Server"
"NEWASD"="SQL Server"
"Login202"="SQL Server"
"LETTERDB"="SQL Server"
"EventA3"="SQL Server"
"A3Friend"="SQL Server"
"HSDB"="SQL Server"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ODBC File DSN]
"DefaultDSNDir"="C:\\Program Files\\Common Files\\ODBC\\Data Sources"



Create the Following directories on your C:\ Drive-

A3log
Clan
Zonelog
A3LogBackup
A3_ClanMarkData


Install BDE ( Borland Database Engine, Included in the server package )

Use the Mkdir.exe inside the \ACCOUNT dir and \CLAN dir to make the directories ( 000-999, Might already be created )

Edit the tdb.ini inside the folders 7770 , 8880, and 9990 to meet your login and password of your sql ( SA in this case )

Accountserver dir

svrinfo.ini
Quote:
#Account Server Info.
[SvrInfo]
ServerVersion=202

#World Information
#酚 MAIN SERVER  CONFIG 跑笆
WorldIndex=0
WorldName=Server

#This Server Information ( 砞﹚ ACCOUNT SERVER )
ThisServerID=255
ThisServerIP=127.0.0.1
ThisServerPort=5589

#MainServer Information ( 砞﹚ MAIN SERVER)
MainServerIP=127.0.0.1
MainServerPort=7789

#Gate count ( 砞﹚ ZONE AGENT 计ヘ )
GateServerNum=1

#Account File DB Path
AccountRootPath=E:\Server\A3server\Account : Edit it to meet your account path

#DB ( comment temporarily )
AccntCharDBServer=Login202
AccntCharDBLogin=sa
AccntCharDBPasswd= your sa password

# For monitoring service
UDPPort=9000
ServicePort=9500


Loginservre dir
Loginserver.ini
Quote:
[STARTUP]
APPNAME=LOGINSERVER
ZONEAGENTLISTENPORT=3200
LOGINAGENTLISTENPORT=3210
STARTID=10063

[LOGINASD]
COUNT=1
IP0=192.168.0.3 Put your wan ip here
PORT0=7770 you might have the wrong port this is the correct

[PAYASD]
COUNT=0
IP0=127.0.0.1
PORT0=3450

[SERVER_GROUP]
COUNT=1

ID0=0
NAME0=Server


Mainserver dir
svrinfo.ini
Quote:
....
...
[ODBC]
ODBCNAME=FriendDB
ODBCID=sa
ODBCPASS= your sa password

[Update Log Info]
ClanPath=C:\clan : Edit to meet your clan dir
LogPath=C:\clan\LOG : Edit to meet your clan dir

[Clan Web DB Info]
SourceName=ASD
UserName=sa
PassWd= your sa password

[ClanInfo]
;bInitNameTable=1
;nSaveClanLog=1

[HSDB]
ODBCNAME=HSDB
ODBCID=sa
ODBCPASS= your sa password


Zoneagent dir
zoneagent.ini

Quote:
[STARTUP]
APPNAME=ZONEAGENT
SERVERID=0
AGENTID=0
#ZONE AGENT 硂柑セ诀 IP
IP=192.168.0.3 : Put your wan ip here
PORT=3300

[ZONESERVER]
COUNT=3


#Account SErver
ID0=255
IP0=127.0.0.1
PORT0=5589

#Zoneserver1
ID1=0
IP1=127.0.0.1
PORT1=6689

#BattleServer
ID2=1
IP2=127.0.0.1
PORT2=6999

[LOGINSERVER]
IP=127.0.0.1
PORT=3200


Start the Server in this Order:

Account = 7770 dir
Character = 8880 dir
ItemStorage = 9990 dir
LoginServer = Loginserver dir
LoginAgent = Loginagent dir
Zoneagent = Zoneagent dir
MainServer= Mainserver dir
Accountserver= Accountserver dir
Zoneserver = Zoneserver dir
Battleserver = Battleserver dir

Credits to Akaruz

ARAIII Client:

http://forums.sunrise-networkz.com/showthread.php?t=315

Provided by PsyKnx
Comment
Watch Question

Commented:
To create the ODBC DSNs Double click the odbc.reg file and say yes when asked if you are sure.

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
no1 ther to replyyyyyyyyyy??????sad :((

Author

Commented:
ty for reply ty very much i will try that sir

Author

Commented:
wher can i find that file?????

Commented:
If the odbc.reg file does not exist then copy the following from your post into a new text file and rename it to odbc.reg - then you can double click that:

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI]

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3Friend ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="FriendDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3RcvRes ult]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="A3ItemEvent"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3Serial List]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="A3ItemEvent"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\EventA3]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\FriendDB ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="HSDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\HSDB]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="HSDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\LETTERDB ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="FriendDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\LocalSer ver]
"Description"=""
"Server"="(Local)"
"Trusted_connection"=""
"UseProcForPrepare"="Yes"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\Login202 ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\NEWASD]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ODBC Data Sources]
"LocalServer"="SQL Server"
"A3RcvResult"="SQL Server"
"A3SerialList"="SQL Server"
"FriendDB"="SQL Server"
"NEWASD"="SQL Server"
"Login202"="SQL Server"
"LETTERDB"="SQL Server"
"EventA3"="SQL Server"
"A3Friend"="SQL Server"
"HSDB"="SQL Server"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ODBC File DSN]
"DefaultDSNDir"="C:\\Program Files\\Common Files\\ODBC\\Data Sources"


Author

Commented:
sire thank you for ur reply but...when i copied all this into a notepad and saved it as odbc.reg on my desktop its giving an error saying that "cannot import(path of file).thi specified fileis not an registry script.u can only import binary register fiels from within the registry editor"...what cud be the problem????

Commented:
Sorry I missed the top line paste the following:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI]

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3Friend ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="FriendDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3RcvRes ult]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="A3ItemEvent"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\A3Serial List]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="A3ItemEvent"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\EventA3]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\FriendDB ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="HSDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\HSDB]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="HSDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\LETTERDB ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="FriendDB"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\LocalSer ver]
"Description"=""
"Server"="(Local)"
"Trusted_connection"=""
"UseProcForPrepare"="Yes"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\Login202 ]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\NEWASD]
"Driver"="C:\\WINDOWS\\System32\\SQLSRV32.dll"
"Server"="(local)"
"Database"="ASD"
"LastUser"="sa"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ODBC Data Sources]
"LocalServer"="SQL Server"
"A3RcvResult"="SQL Server"
"A3SerialList"="SQL Server"
"FriendDB"="SQL Server"
"NEWASD"="SQL Server"
"Login202"="SQL Server"
"LETTERDB"="SQL Server"
"EventA3"="SQL Server"
"A3Friend"="SQL Server"
"HSDB"="SQL Server"

[HKEY_LOCAL_MACHINE\SOFTWARE\ODBC\ODBC.INI\ODBC File DSN]
"DefaultDSNDir"="C:\\Program Files\\Common Files\\ODBC\\Data Sources"

Author

Commented:
yes thank you its worked...i clicked on the files and pressed yes..so the DSNs created?????

Commented:
They should be now created yes.  Make sure you create the databases before trying to open the DSNs

Author

Commented:
below is a txt file got frm frn for me.....he told me to crete a databse with this...in sql i created named a3itemevent..but im nt getting how to and wher to put this file into???can u plz help me wher can i copy this files into???

if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[HSSTONETABLE]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[HSSTONETABLE]
GO

if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[HSTABLE]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[HSTABLE]
GO

CREATE TABLE [dbo].[HSSTONETABLE] (
      [MasterName] [char] (21) COLLATE Chinese_Taiwan_Stroke_CS_AS NOT NULL ,
      [CreateDate] [smalldatetime] NULL ,
      [SaveDate] [smalldatetime] NULL ,
      [Slot0] [char] (256) COLLATE Chinese_Taiwan_Stroke_CS_AS NULL ,
      [Slot1] [char] (256) COLLATE Chinese_Taiwan_Stroke_CS_AS NULL ,
      [Slot2] [char] (256) COLLATE Chinese_Taiwan_Stroke_CS_AS NULL ,
      [Slot3] [char] (256) COLLATE Chinese_Taiwan_Stroke_CS_AS NULL
) ON [PRIMARY]
GO

CREATE TABLE [dbo].[HSTABLE] (
      [HSID] [int] IDENTITY (1, 1) NOT NULL ,
      [HSName] [char] (21) COLLATE Chinese_Taiwan_Stroke_CS_AS NOT NULL ,
      [MasterName] [char] (21) COLLATE Chinese_Taiwan_Stroke_CS_AS NOT NULL ,
      [Type] [tinyint] NOT NULL ,
      [HSLevel] [smallint] NOT NULL ,
      [HSExp] [int] NOT NULL ,
      [Ability] [char] (256) COLLATE Chinese_Taiwan_Stroke_CS_AS NOT NULL ,
      [CreateDate] [smalldatetime] NOT NULL ,
      [SaveDate] [smalldatetime] NOT NULL ,
      [HSState] [tinyint] NULL ,
      [DelDate] [smalldatetime] NULL ,
      [HSBody] [char] (1024) COLLATE Chinese_Taiwan_Stroke_CS_AS NOT NULL
) ON [PRIMARY]
GO

Commented:
copy the script into a query window and run it.  Put this at the top of your script before your un the script:

USE a3itemevent
GO



Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.