Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - SQL Server Script Issues...
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

SQL Server Script Issues...

 Post Reply Post Reply Page  12>
Author
Sean T View Drop Down
Newbie
Newbie


Joined: 24 November 2003
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote Sean T Quote  Post ReplyReply Direct Link To This Post Topic: SQL Server Script Issues...
    Posted: 24 November 2003 at 9:33am

I've been searching through the forum looking for someone who has had a problem with the 7.6 SQLServer scripts.  Can't find anyone (or they're not talking) so here goes:

First after running the script on my new blank db I could not login.  If found that none of the "seed" values were inserted into the db so the administrator/letmein login wouldn't work.  I opened the Access db and copied the seed values from 4-5 tables into the SQLServer db.

Next problem was when setting up a new forum category, I get an error on the Cat_Order column which requires a value.  I altered the SQLServer db to default that column to 1 as in the Access db.

Now I'm getting an error on No_of_Posts while attempting to create a new forum.  Which I'll do another alter of the SQLServer db to correct.

So my question is, is there a more recent version of the SQLServer script that fixes these issues and maybe the others I've not yet hit?  The version I have is the one in the zip from the US Mirror that I downloaded this morning...

Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 24 November 2003 at 9:45am
Don't use the file Web_wiz_forums.sq. file. This is only there for reference.

Follow the documentation on how to setup the forums!!!

You will find that there is an online database creation file written in ASP that creates the database with all the tables, default values, indexes, stored procedures, etc.
Back to Top
Sean T View Drop Down
Newbie
Newbie


Joined: 24 November 2003
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote Sean T Quote  Post ReplyReply Direct Link To This Post Posted: 24 November 2003 at 9:56am

And a big ol' DUH HUH goes out to me. 

Thanks for the heads up.  Works great now.

Back to Top
Spartanx15 View Drop Down
Newbie
Newbie


Joined: 23 November 2003
Location: United States
Status: Offline
Points: 9
Post Options Post Options   Thanks (0) Thanks(0)   Quote Spartanx15 Quote  Post ReplyReply Direct Link To This Post Posted: 24 November 2003 at 4:57pm

I have tried the online SQL DB creation system and got a message about "errors". I am using an SQL 7.0 SPK4 DB. I have deleted the DB and tried to create it using ISQL I got an error on the COLLATE statement. I modifed the .sql file and started over again. Noe I am getting another error on the "ServerProperty" section, which SQL 7.0 does not support ( see seperate post of this date on this problem ).

So..... what is one to do. If the .sql file does not create the seeds and the online ASP system sends an obtuse message on "errors" but does not describe them...what should I do ?

BTW I do love the forum, which is why I supported it. Only my 6 version is working fine and with the SQL errors I found in 7.0, 7.1 and now with my finding errors in making the SQL 7.0 DB, maybe I should stay with 6.0 ?

Jon Spartanx15 email: jonux@ixtech.net

Back to Top
thekiwi View Drop Down
Mod Builder Group
Mod Builder Group


Joined: 23 November 2003
Location: New Zealand
Status: Offline
Points: 392
Post Options Post Options   Thanks (0) Thanks(0)   Quote thekiwi Quote  Post ReplyReply Direct Link To This Post Posted: 24 November 2003 at 5:04pm

I have tried the online SQL DB creation system and got a message about "errors". I am using an SQL 7.0 SPK4 DB. I have deleted the DB and tried to create it using ISQL I got an error on the COLLATE statement. I modifed the .sql file and started over again. Noe I am getting another error on the "ServerProperty" section, which SQL 7.0 does not support ( see seperate post of this date on this problem ).

What "Errors" did you get running msSQL_server_setup.asp ?

In the ASP file there are no Collate statements or ServerProperty calls ... so it should work OK.

What line number etc?

Back to Top
Spartanx15 View Drop Down
Newbie
Newbie


Joined: 23 November 2003
Location: United States
Status: Offline
Points: 9
Post Options Post Options   Thanks (0) Thanks(0)   Quote Spartanx15 Quote  Post ReplyReply Direct Link To This Post Posted: 24 November 2003 at 5:11pm

Here is what I got back when I just re-ran the ASP Script - msSQL_server_setup.asp

"Error Creating the Stored Procedure wwfSpDBinfo (it may already exsist)

SQL Server database is set up, but with Error! "

 

This error was shown directly under the SQL Sever Usernamae and password "box"

Back to Top
Spartanx15 View Drop Down
Newbie
Newbie


Joined: 23 November 2003
Location: United States
Status: Offline
Points: 9
Post Options Post Options   Thanks (0) Thanks(0)   Quote Spartanx15 Quote  Post ReplyReply Direct Link To This Post Posted: 24 November 2003 at 5:20pm
I also just checked the stored procedures list under the DB and wwfSpDBinfo DOES NOT exist.
Back to Top
Spartanx15 View Drop Down
Newbie
Newbie


Joined: 23 November 2003
Location: United States
Status: Offline
Points: 9
Post Options Post Options   Thanks (0) Thanks(0)   Quote Spartanx15 Quote  Post ReplyReply Direct Link To This Post Posted: 24 November 2003 at 5:25pm

The code from the ASP script follows - once again the "ServerProerty" statement is used which is not support by 7.0 - SO - how do we correct this pray tell ???

 

Script portion is -

 

  strSQL = "CREATE PROCEDURE [dbo].[" & strDbProc & "DBinfo] "
  strSQL = strSQL & "As "
  strSQL = strSQL & vbCrLf & "Declare @low int"
  strSQL = strSQL & vbCrLf & "Declare @dbsize dec(10,2)"
  strSQL = strSQL & vbCrLf & "Declare @dbpath nvarchar(100)"
  strSQL = strSQL & vbCrLf & "Declare @logpath nvarchar(100)"
  strSQL = strSQL & vbCrLf & "Declare @dbfilesize dec(10,2)"
  strSQL = strSQL & vbCrLf & "Declare @logfilesize dec(10,2)"
  strSQL = strSQL & vbCrLf & "Declare @maxdbfilesize dec(10,2)"
  strSQL = strSQL & vbCrLf & "Declare @maxlogfilesize dec(10,2)"
  strSQL = strSQL & vbCrLf & " "
  strSQL = strSQL & vbCrLf & "--Minimum Database Size"
  strSQL = strSQL & vbCrLf & "select @low = low from master.dbo.spt_values"
  strSQL = strSQL & vbCrLf & "   where type = N'E' and number = 1"
  strSQL = strSQL & vbCrLf & "--Calculation of current Database Size in MB"
  strSQL = strSQL & vbCrLf & "select @dbsize = (convert(dec(15),sum(size)) *  @low  / 1048576)"
  strSQL = strSQL & vbCrLf & "from [sysfiles]"
  strSQL = strSQL & vbCrLf & "--Actual File Size of Log and Data File"
  strSQL = strSQL & vbCrLf & "Select TOP 1 @dbpath = [filename] from [sysfiles] where groupid = 1"
  strSQL = strSQL & vbCrLf & "Select TOP 1 @logpath = [filename] from [sysfiles] where groupid = 0"
  strSQL = strSQL & vbCrLf & "Select @dbfilesize =  convert(dec(10,2),sum([size]))/128 from [sysfiles] where [filename] = @dbpath     --in MB"
  strSQL = strSQL & vbCrLf & "Select @logfilesize = convert(dec(10,2),sum([size]))/128 from [sysfiles] where [filename] = @logpath   --in MB"
  strSQL = strSQL & vbCrLf & "Select TOP 1 @maxdbfilesize = convert(dec(10,2),[maxsize])/128 from [sysfiles] where [filename] = @dbpath"
  strSQL = strSQL & vbCrLf & "Select TOP 1 @maxlogfilesize = convert(dec(10,2),[maxsize])/128 from [sysfiles] where [filename] = @logpath"
  strSQL = strSQL & vbCrLf & "If @maxdbfilesize = (-.01) Set @maxdbfilesize = -1"
  strSQL = strSQL & vbCrLf & "If @maxlogfilesize = (-.01) Set @maxlogfilesize = -1"
  strSQL = strSQL & vbCrLf & " "
  strSQL = strSQL & vbCrLf & "---Creating Output Table"
  strSQL = strSQL & vbCrLf & "select  @dbsize Databasesize, @dbpath DataLocation , @logpath LogLocation, "
  strSQL = strSQL & vbCrLf & " @dbfilesize DatabaseFileSize, @logfilesize Logfilesize,"
  strSQL = strSQL & vbCrLf & " @maxdbfilesize MaxDBSize, @maxlogfilesize MazLogSize,"
  strSQL = strSQL & vbCrLf & " ServerProperty('edition') Edition, "
  strSQL = strSQL & vbCrLf & " CASE ServerProperty('IsCluster') "
  strSQL = strSQL & vbCrLf & "  WHEN 0 THEN 'No Cluster'"
  strSQL = strSQL & vbCrLf & "  WHEN 1 THEN 'Cluster'"
  strSQL = strSQL & vbCrLf & "   ELSE  'No Cluster/Unknown' "
  strSQL = strSQL & vbCrLf & " END Cluster,"
  strSQL = strSQL & vbCrLf & " CASE ServerProperty('License_Type')"
  strSQL = strSQL & vbCrLf & "  WHEN 'PER_SEAT' THEN 'Seat Licensing (' + Convert(nvarchar(5),ServerProperty('NumLicenses')) + ')'"
  strSQL = strSQL & vbCrLf & "  WHEN 'Per_Processor' THEN 'Processor Licensing (' + Convert(nvarchar(5),ServerProperty('NumLicenses')) + ')'"
  strSQL = strSQL & vbCrLf & "  ELSE 'Licensing Disabled / Unknown'"
  strSQL = strSQL & vbCrLf & " END Licensing,"
  strSQL = strSQL & vbCrLf & " ServerProperty('ProductLevel') PLevel"

Back to Top
 Post Reply Post Reply Page  12>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.