Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 DEV-Group
 DEV Discussions (General)
 MOD Bug/Fix: DB -> DNS
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

BeerGeek
Starting Member

USA
4 Posts

Posted - 22 October 2002 :  14:15:53  Show Profile  Visit BeerGeek's Homepage
I noticed this bug when attempting to implement a MOD for the first time. In this example, I was installing the Avatar, however the bug will occur with any instance requiring a CREATE TABLE SQL execution with the following conditions:
  • strDBType = "access"

  • strConnString -> DNS


Error Message:
CREATE TABLE FORUM_AVATAR(
 A_ID int IDENTITY (1, 1) PRIMARY KEY
 NOT NULL , A_URL text (255) NULL ,
 A_NAME text (50) NULL ,
 A_MEMBER_ID int NULL )
Table already exists

Notes:
The table was never created because Access generates an error on the SQL script. The correct SQL stament should be:
CREATE TABLE FORUM_AVATAR(
 A_ID COUNTER CONSTRAINT PrimaryKey PRIMARY KEY ,
 A_URL text (255) NULL ,
 A_NAME text (50) NULL ,
 A_MEMBER_ID int NULL )
The bug is specific to Access AND setting strConnString to a DNS.

To FIX:
  • Open "admin_mod_dbsetup.asp"

  • Goto Line 270:
    if Instr(strConnString,"(*.mdb)") then

  • Replace Lines 270 to 274 with this line:
    strSql = strSql & idFieldName &
    " COUNTER CONSTRAINT PrimaryKey PRIMARY KEY "

Request:
Addendum or revision to "readme.htm" DSN section suggesting this modification.

Thanks to all for an otherwise creative offering

Edited by - BeerGeek on 22 October 2002 15:28:16
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.17 seconds. Powered By: Snitz Forums 2000 Version 3.4.07