Run in any query , of your SQL server :
Set Dateformat mdy
Thanks micro. How can i do that? Can you show me in details. Sorry I could not set it up for few years!
I did all the step that Vomav's showed us but i could not figure out what actually i went wrong.
open your SQL server, connect it, so do a right click in Any db and Select > "New Query", past it :
Set Dateformat mdy
press F9, and it was done =D
( you will se the message : Query run sucefful )
That's in MS SQL Management Studio, I presume. ;) (disclaimer: Other SQL managers exist with similar functionality, operational specifics may vary lol)
So can I repeat the steps:
1. Open my MS SQL Management Studio
2. pick up any db and select New Query then "past it" I understand here how can i pass it?
3. set Dateformat. Sorry guys, but Just wondering do i need to put any thing in new query to set Dateformat mdy?
4. Press F9
Please tell me again cuz I am not good at those. Thank you!
"Set Dateformat mdy" is the command you pasted in, and then you click the little "play" symbol (internationally recognised as a green triangle pointing to the right) to "run" the query. (I think that's Microsofts terminology? Either "Run" or "Execute".)
Thank you very much Mod. I'll try it when i get home form work.
Sorry guys but it does bot help. Just say what I have done:
Open up my MS SQL Management Studio
right click on any DB and new query---> Filled Set Dateformat mdy up in the new query and hit Execute button and there is a message Command(s) completed successfully. Went back and check again the problem still persists as same as before.
Really wanna know how to fix the SOD score. I have trying on ISS using Sandurr's files and on Apache on Vovma's files. I could create clan and all the functions but went i try the SOD score i got all fails.
past that script here and we can find where the problem is =D
Here it is. Thanks buds!
<%--
Written by Vormav
--%>
<%@ Page language="vb" aspcompat="true" Debug="true"%>
<%@ Import Namespace = "nce.scripting" %>
<%
Dim SNo As String = Request.QueryString("SNo")
Dim yyMM As String = DateTime.Now.ToString("yyMM")
Dim dbhost = "127.0.0.1"
Dim dbname = "ClanDB"
Dim dbuser = "clan"
Dim dbpass = "clan"
%>
<%
ODBC_String = "Provider=SQLOLEDB; Data Source=" & dbhost & "; Initial Catalog=" & dbname & "; User ID=" & dbuser & "; Password=" & dbpass
ODBC_Connect = new ADODB.ConnectionClass()
ODBC_Connect.Open(ODBC_String)
ODBC_Record = new ADODB.Recordset()
ODBC_Record.Open("INSERT INTO soddb.dbo.sod2clan" & yyMM & " SELECT clandb.dbo.ul.ChName,Point, RegistDay, ClanName FROM clandb.dbo.ul, soddb.dbo.sod2record" & yyMM & " WHERE clandb.dbo.ul.ChName = soddb.dbo.sod2record" & yyMM & ".charname AND SNo = " & SNo & " AND RegistDay BETWEEN (dateadd(minute,-1,getdate())) AND (dateadd(minute,+1,getdate()))", ODBC_Connect, 3, 1)
ODBC_Record.Open("UPDATE ClanDb.dbo.CL SET RegiDate = GETDATE(), Cpoint = (SELECT SUM(Point) FROM SodDb.dbo.Sod2Clan" & yyMM & " WHERE SodDb.dbo.Sod2Clan" & yyMM & ".RegistDay BETWEEN (dateadd(minute,-1,getdate())) AND (dateadd(minute,+1,getdate())) AND ClanName = (SELECT clandb.dbo.ul.ClanName FROM ClanDB.dbo.UL INNER JOIN soddb.dbo.sod2record" & yyMM & " ON SNo = " & SNo & " AND clandb.dbo.ul.ChName = soddb.dbo.sod2record" & yyMM & ".CharName)) WHERE ClanName=(SELECT clandb.dbo.ul.ClanName FROM clandb.dbo.UL INNER JOIN soddb.dbo.sod2record" & yyMM & " ON SNo = " & SNo & " AND clandb.dbo.ul.ChName = soddb.dbo.sod2record" & yyMM & ".charname) AND ClanDB.dbo.CL.Cpoint <= (SELECT SUM(Point) FROM SodDb.dbo.sod2clan" & yyMM & " WHERE SodDb.dbo.Sod2Clan" & yyMM & ".RegistDay BETWEEN (dateadd(minute,-1,getdate())) AND (dateadd(minute,+1,getdate())) AND ClanName = (SELECT clandb.dbo.ul.ClanName FROM clandb.dbo.ul INNER JOIN soddb.dbo.sod2record" & yyMM & " ON SNo = " & SNo & " AND clandb.dbo.ul.ChName = soddb.dbo.sod2record" & yyMM & ".charname))", ODBC_Connect, 3, 1)
Response.Write("Bellatra")
Response.End()
ODBC_Record.Close()
%>
<script language="vb" runat="server">
Dim ODBC_String As String
Dim ODBC_Connect As Object ' ADODB.Connection
Dim ODBC_Record As Object ' ADODB.Recordset
</script>
try execute this query :
INSERT INTO soddb.dbo.sod2clan1304 SELECT clandb.dbo.ul.ChName,Point, RegistDay, ClanName FROM clandb.dbo.ul, soddb.dbo.sod2record1304 WHERE clandb.dbo.ul.ChName = soddb.dbo.sod2record1304.charname AND SNo = 1 AND RegistDay BETWEEN (dateadd(minute,-1,getdate())) AND (dateadd(minute,+1,getdate()))
which db am I going to execute? Any DB?
I have tired on soddb and got the message:
Msg 208, Level 16, State 1, Line 1
Invalid object name 'soddb.dbo.sod2record1304'.
Last edited by Owall; 03-04-13 at 04:43 PM.
Wait, wait. Sandurrs system and Vormavs are completely different. You know that right? With Sandurrs you need his Clan SoD Manager running, and various modifications to the database. Vormavs doesn't need a background processor, and I'm not sure if his DB differs from the basic one.
Regardless, the date format needs to be set before any account is created, or the ASP scripts will fail.