webForumDet fria alternativet

Felmeddelande...

ASP

14 svar · 703 visningar · startad av Lorelie

Medlem sedan juni 2005264 inlägg
Frågan#1

VAD är det som är fel?


<%
hast_id = Request.Querystring("hast_id")

Set MinCon = Server.Createobject("ADODB.Connection")
Set rs = Server.CreateObject("ADODB.Recordset")
Set rsAntAvk = Server.CreateObject("ADODB.Recordset")
MinCon.Open "DRIVER={MySQL};SERVER=localhost;DATABASE=aramennoc_se;UID=aramennoc_se;PWD=xxxxxxxxx;"
%>

<%
sAntAvk = 	"	SELECT COUNT(*)AS 		ant 							" & _
			"	FROM 					connemara 						" & _
			"	WHERE 					pappa 	= 	" & hast_id & " 	" & _
			"	OR 						mamma 	= 	" & hast_id & "		"

rsAntAvk.Open sAntAvk, MinCon
intAntAvk = CInt(rsAntAvk(0))
rsAntAvk.Close
%>

Felmeddelandet ser ut såhär

Error Type:
ADODB.Recordset.1 (0x80004005)
SQLState: 4 Native Error Code: 1064 [TCX][MyODBC]You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'OR mamma =' at line 1
/databas/hast.asp, line 27

Rad 27 är rsAntAvk.Open sAntAvk, MinCon

Medlem sedan maj 20033 218 inlägg
#2

Skriv ut SQL frågan!

Medlem sedan juni 2005264 inlägg
#3

Sjodahl skrev:

Skriv ut SQL frågan!

Menar du


<%
SQL	 = 		"SELECT 	h.namn,										" & _
			"			h.kon,										" & _
			"			h.reg_nr,									" & _
			"			h.stamboks_nr,								" & _
			"			h.ras,										" & _
			"			h.fodd,										" & _
			"			h.dod,										" & _
			"			h.farg,										" & _
			"			h.tecken,									" & _
			"			h.mankhojd,									" & _
			"			h.uppfodare, 								" & _
			"			h.inskickad_av,								" & _
			"			h.inskickad_av_mail,						" & _
			"			h.ovrigt,									" & _
			"			h.premierad,								" & _
			"			h.utlatande,								" & _
			"			h.verksam,									" & _
			"			h.imp,										" & _
			"			h.exp,										" & _
			"			h.utlstbnr,									" & _
			"			h.bild,										" & _
			"			he.namn 		AS e,						" & _
			"			he.hast_id 		AS e_id,					" & _
			"			hu.namn	 		AS u,						" & _
			"			hu.hast_id 		AS u_id,					" & _
			"			hee.namn	 	AS ee,						" & _
			"			hee.hast_id 	AS ee_id,					" & _
			"			heu.namn	 	AS eu,						" & _
			"			heu.hast_id 	AS eu_id,					" & _
			"			hue.namn	 	AS ue,						" & _
			"			hue.hast_id 	AS ue_id,					" & _
			"			huu.namn	 	AS uu,						" & _
			"			huu.hast_id 	AS uu_id,					" & _
			"			heee.namn	 	AS eee,						" & _
			"			heee.hast_id 	AS eee_id,					" & _
			"			heeu.namn	 	AS eeu,						" & _
			"			heeu.hast_id 	AS eeu_id,					" & _
			"			heue.namn	 	AS eue,						" & _
			"			heue.hast_id 	AS eue_id,					" & _
			"			heuu.namn	 	AS euu,						" & _
			"			heuu.hast_id 	AS euu_id,					" & _
			"			huee.namn	 	AS uee,						" & _
			"			huee.hast_id 	AS uee_id,					" & _
			"			hueu.namn	 	AS ueu,						" & _
			"			hueu.hast_id 	AS ueu_id,					" & _
			"			huue.namn	 	AS uue,						" & _
			"			huue.hast_id 	AS uue_id,					" & _
			"			huuu.namn	 	AS uuu,						" & _
			"			huuu.hast_id 	AS uuu_id,					" & _
			"			heeee.namn	 	AS eeee,					" & _
			"			heeee.hast_id 	AS eeee_id,					" & _
			"			heeeu.namn	 	AS eeeu,					" & _
			"			heeeu.hast_id 	AS eeeu_id,					" & _
			"			heeue.namn	 	AS eeue,					" & _
			"			heeue.hast_id 	AS eeue_id,					" & _
			"			heeuu.namn	 	AS eeuu,					" & _
			"			heeuu.hast_id 	AS eeuu_id,					" & _
			"			heuee.namn	 	AS euee,					" & _
			"			heuee.hast_id 	AS euee_id,					" & _
			"			heueu.namn	 	AS eueu,					" & _
			"			heueu.hast_id 	AS eueu_id,					" & _
			"			heuue.namn	 	AS euue,					" & _
			"			heuue.hast_id 	AS euue_id,					" & _
			"			heuuu.namn	 	AS euuu,					" & _
			"			heuuu.hast_id 	AS euuu_id,					" & _
			"			hueee.namn	 	AS ueee,					" & _
			"			hueee.hast_id 	AS ueee_id,					" & _
			"			hueeu.namn	 	AS ueeu,					" & _
			"			hueeu.hast_id 	AS ueeu_id,					" & _
			"			hueue.namn	 	AS ueue,					" & _
			"			hueue.hast_id 	AS ueue_id,					" & _
			"			hueuu.namn	 	AS ueuu,					" & _
			"			hueuu.hast_id 	AS ueuu_id,					" & _
			"			huuee.namn	 	AS uuee,					" & _
			"			huuee.hast_id 	AS uuee_id,					" & _
			"			huueu.namn	 	AS uueu,					" & _
			"			huueu.hast_id 	AS uueu_id,					" & _
			"			huuue.namn	 	AS uuue,					" & _
			"			huuue.hast_id 	AS uuue_id,					" & _
			"			huuuu.namn	 	AS uuuu,					" & _
			"			huuuu.hast_id 	AS uuuu_id					" & _
			"FROM 		connemara h,									" & _
			"			connemara he, 									" & _
			"			connemara hu, 									" & _
			"			connemara hee, 									" & _
			"			connemara heu, 									" & _
			"			connemara hue, 									" & _
			"			connemara huu, 									" & _
			"			connemara heee, 								" & _
			"			connemara heeu, 								" & _
			"			connemara heue, 								" & _
			"			connemara heuu,									" & _
			"			connemara huee, 								" & _
			"			connemara hueu, 								" & _
			"			connemara huue, 								" & _
			"			connemara huuu, 								" & _
			"			connemara heeee, 								" & _
			"			connemara heeeu, 								" & _
			"			connemara heeue, 								" & _
			"			connemara heeuu, 								" & _
			"			connemara heuee, 								" & _
			"			connemara heueu, 								" & _
			"			connemara heuue, 								" & _
			"			connemara heuuu, 								" & _
			"			connemara hueee, 								" & _
			"			connemara hueeu, 								" & _
			"			connemara hueue, 								" & _
			"			connemara hueuu, 								" & _
			"			connemara huuee, 								" & _
			"			connemara huueu, 								" & _
			"			connemara huuue, 								" & _
			"			connemara huuuu 								" & _
			"WHERE 	h.hast_id = "& hast_id &" 							" & _
			"AND		h.pappa = he.hast_id							" & _
			"AND		h.mamma = hu.hast_id							" & _
			"AND		he.pappa = hee.hast_id					" & _
			"AND		he.mamma = heu.hast_id					" & _
			"AND		hu.pappa = hue.hast_id					" & _
			"AND		hu.mamma = huu.hast_id					" & _
			"AND		hee.pappa = heee.hast_id				" & _
			"AND		hee.mamma = heeu.hast_id				" & _
			"AND		heu.pappa = heue.hast_id				" & _
			"AND		heu.mamma = heuu.hast_id				" & _
			"AND		hue.pappa = huee.hast_id				" & _
			"AND		hue.mamma = hueu.hast_id				" & _
			"AND		huu.pappa = huue.hast_id				" & _
			"AND		huu.mamma = huuu.hast_id				" & _
			"AND		heee.pappa = heeee.hast_id				" & _
			"AND		heee.mamma = heeeu.hast_id				" & _
			"AND		heeu.pappa = heeue.hast_id				" & _
			"AND		heeu.mamma = heeuu.hast_id				" & _
			"AND		heue.pappa = heuee.hast_id				" & _
			"AND		heue.mamma = heueu.hast_id				" & _
			"AND		heuu.pappa = heuue.hast_id				" & _
			"AND		heuu.mamma = heuuu.hast_id				" & _
			"AND		huee.pappa = hueee.hast_id				" & _
			"AND		huee.mamma = hueeu.hast_id				" & _
			"AND		hueu.pappa = hueue.hast_id				" & _
			"AND		hueu.mamma = hueuu.hast_id				" & _
			"AND		huue.pappa = huuee.hast_id				" & _
			"AND		huue.mamma = huueu.hast_id				" & _
			"AND		huuu.pappa = huuue.hast_id				" & _
			"AND		huuu.mamma = huuuu.hast_id				"

rs.Open SQL, MinCon

Session("connemara_namn")=rs("namn")
utl = rs("utlatande")
ovr = rs("ovrigt")
%>

Fast frågan är om det inte ska stå c istället för h... min databas heter connemara...
Har fått sidan av en kompis, min sida ska vara likdan som hennes i stort sett, än så länge har jag bara ändrat namn osv så de ska passa min databas... har inte gjort något åt själva kodningen i övrigt.

Får felmeddelande

#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '<%
SQL = "SELECT h.namn, " & _
" h.kon,

Medlem sedan juni 2005264 inlägg
#4

Såhär ska det enligt B-One se ut:


<%

Dim objConn
Dim objRS
Set objRS = Server.CreateObject("ADODB.Recordset")
Set objConn = Server.CreateObject("ADODB.Connection")

objConn.ConnectionString="DRIVER={MySQL};SERVER=localhost;DATABASE=
[DOMAIN_COM];UID=[DOMAIN_COM];PWD=[PASSWORD];"
objConn.Open

objRS.Open "[QUERY]", objConn, 3,3

%>

<%
objRS.Close
Set objRS = Nothing

objConn.Close
Set objConn = Nothing

%>

Såhär ser min kod ut:


<%
hast_id = Request.Querystring("hast_id")

Set MinCon = Server.Createobject("ADODB.Connection")
Set rs = Server.CreateObject("ADODB.Recordset")
Set rsAntAvk = Server.CreateObject("ADODB.Recordset")
MinCon.Open "DRIVER={MySQL};SERVER=localhost;DATABASE=aramennoc_se;UID=aramennoc_se;PWD=xxxxxxxx;"
%>

<%
sAntAvk = 	"	SELECT COUNT(*)AS 		ant 							" & _
			"	FROM 					connemara 						" & _
			"	WHERE 					pappa 	= 	" & hast_id & " 	" & _
			"	OR 						mamma 	= 	" & hast_id & "		"

rsAntAvk.Open sAntAvk, MinCon
intAntAvk = CInt(rsAntAvk(0))
rsAntAvk.Close
%>

<%
SQL	 = 		"SELECT 	c.namn,										" & _
			"			c.kon,										" & _
			"			c.reg_nr,									" & _
			"			c.stamboks_nr,								" & _
			"			c.ras,										" & _
			"			c.fodd,										" & _
			"			c.dod,										" & _
			"			c.farg,										" & _
			"			c.tecken,									" & _
			"			c.mankhojd,									" & _
			"			c.uppfodare, 								" & _
			"			c.inskickad_av,								" & _
			"			c.inskickad_av_mail,						" & _
			"			c.ovrigt,									" & _
			"			c.premierad,								" & _
			"			c.utlatande,								" & _
			"			c.verksam,									" & _
			"			c.imp,										" & _
			"			c.exp,										" & _
			"			c.utlstbnr,									" & _
			"			c.bild,										" & _
			"			ce.namn 		AS e,						" & _
			"			ce.hast_id 		AS e_id,					" & _
			"			cu.namn	 		AS u,						" & _
			"			cu.hast_id 		AS u_id,					" & _
			"			cee.namn	 	AS ee,						" & _
			"			cee.hast_id 	AS ee_id,					" & _
			"			ceu.namn	 	AS eu,						" & _
			"			ceu.hast_id 	AS eu_id,					" & _
			"			cue.namn	 	AS ue,						" & _
			"			cue.hast_id 	AS ue_id,					" & _
			"			cuu.namn	 	AS uu,						" & _
			"			cuu.hast_id 	AS uu_id,					" & _
			"			ceee.namn	 	AS eee,						" & _
			"			ceee.hast_id 	AS eee_id,					" & _
			"			ceeu.namn	 	AS eeu,						" & _
			"			ceeu.hast_id 	AS eeu_id,					" & _
			"			ceue.namn	 	AS eue,						" & _
			"			ceue.hast_id 	AS eue_id,					" & _
			"			ceuu.namn	 	AS euu,						" & _
			"			ceuu.hast_id 	AS euu_id,					" & _
			"			cuee.namn	 	AS uee,						" & _
			"			huee.hast_id 	AS uee_id,					" & _
			"			cueu.namn	 	AS ueu,						" & _
			"			cueu.hast_id 	AS ueu_id,					" & _
			"			cuue.namn	 	AS uue,						" & _
			"			cuue.hast_id 	AS uue_id,					" & _
			"			cuuu.namn	 	AS uuu,						" & _
			"			cuuu.hast_id 	AS uuu_id,					" & _
			"			ceeee.namn	 	AS eeee,					" & _
			"			ceeee.hast_id 	AS eeee_id,					" & _
			"			ceeeu.namn	 	AS eeeu,					" & _
			"			ceeeu.hast_id 	AS eeeu_id,					" & _
			"			ceeue.namn	 	AS eeue,					" & _
			"			ceeue.hast_id 	AS eeue_id,					" & _
			"			ceeuu.namn	 	AS eeuu,					" & _
			"			ceeuu.hast_id 	AS eeuu_id,					" & _
			"			ceuee.namn	 	AS euee,					" & _
			"			ceuee.hast_id 	AS euee_id,					" & _
			"			ceueu.namn	 	AS eueu,					" & _
			"			ceueu.hast_id 	AS eueu_id,					" & _
			"			ceuue.namn	 	AS euue,					" & _
			"			ceuue.hast_id 	AS euue_id,					" & _
			"			ceuuu.namn	 	AS euuu,					" & _
			"			ceuuu.hast_id 	AS euuu_id,					" & _
			"			cueee.namn	 	AS ueee,					" & _
			"			cueee.hast_id 	AS ueee_id,					" & _
			"			cueeu.namn	 	AS ueeu,					" & _
			"			cueeu.hast_id 	AS ueeu_id,					" & _
			"			cueue.namn	 	AS ueue,					" & _
			"			cueue.hast_id 	AS ueue_id,					" & _
			"			cueuu.namn	 	AS ueuu,					" & _
			"			cueuu.hast_id 	AS ueuu_id,					" & _
			"			cuuee.namn	 	AS uuee,					" & _
			"			cuuee.hast_id 	AS uuee_id,					" & _
			"			cuueu.namn	 	AS uueu,					" & _
			"			cuueu.hast_id 	AS uueu_id,					" & _
			"			cuuue.namn	 	AS uuue,					" & _
			"			cuuue.hast_id 	AS uuue_id,					" & _
			"			cuuuu.namn	 	AS uuuu,					" & _
			"			cuuuu.hast_id 	AS uuuu_id					" & _
			"FROM 		connemara c,									" & _
			"			connemara ce, 									" & _
			"			connemara cu, 									" & _
			"			connemara cee, 									" & _
			"			connemara ceu, 									" & _
			"			connemara cue, 									" & _
			"			connemara cuu, 									" & _
			"			connemara ceee, 								" & _
			"			connemara ceeu, 								" & _
			"			connemara ceue, 								" & _
			"			connemara ceuu,									" & _
			"			connemara cuee, 								" & _
			"			connemara cueu, 								" & _
			"			connemara cuue, 								" & _
			"			connemara cuuu, 								" & _
			"			connemara ceeee, 								" & _
			"			connemara ceeeu, 								" & _
			"			connemara ceeue, 								" & _
			"			connemara ceeuu, 								" & _
			"			connemara ceuee, 								" & _
			"			connemara ceueu, 								" & _
			"			connemara ceuue, 								" & _
			"			connemara ceuuu, 								" & _
			"			connemara cueee, 								" & _
			"			connemara cueeu, 								" & _
			"			connemara cueue, 								" & _
			"			connemara cueuu, 								" & _
			"			connemara cuuee, 								" & _
			"			connemara cuueu, 								" & _
			"			connemara cuuue, 								" & _
			"			connemara cuuuu 								" & _
			"WHERE 	h.hast_id = "& hast_id &" 							" & _
			"AND		c.pappa = ce.hast_id							" & _
			"AND		c.mamma = cu.hast_id							" & _
			"AND		ce.pappa = cee.hast_id					" & _
			"AND		ce.mamma = ceu.hast_id					" & _
			"AND		cu.pappa = cue.hast_id					" & _
			"AND		cu.mamma = cuu.hast_id					" & _
			"AND		cee.pappa = ceee.hast_id				" & _
			"AND		cee.mamma = ceeu.hast_id				" & _
			"AND		ceu.pappa = ceue.hast_id				" & _
			"AND		ceu.mamma = ceuu.hast_id				" & _
			"AND		cue.pappa = cuee.hast_id				" & _
			"AND		cue.mamma = cueu.hast_id				" & _
			"AND		cuu.pappa = cuue.hast_id				" & _
			"AND		cuu.mamma = cuuu.hast_id				" & _
			"AND		ceee.pappa = ceeee.hast_id				" & _
			"AND		ceee.mamma = ceeeu.hast_id				" & _
			"AND		ceeu.pappa = ceeue.hast_id				" & _
			"AND		ceeu.mamma = ceeuu.hast_id				" & _
			"AND		ceue.pappa = ceuee.hast_id				" & _
			"AND		ceue.mamma = ceueu.hast_id				" & _
			"AND		ceuu.pappa = ceuue.hast_id				" & _
			"AND		ceuu.mamma = ceuuu.hast_id				" & _
			"AND		cuee.pappa = cueee.hast_id				" & _
			"AND		cuee.mamma = cueeu.hast_id				" & _
			"AND		cueu.pappa = cueue.hast_id				" & _
			"AND		cueu.mamma = cueuu.hast_id				" & _
			"AND		cuue.pappa = cuuee.hast_id				" & _
			"AND		cuue.mamma = cuueu.hast_id				" & _
			"AND		cuuu.pappa = cuuue.hast_id				" & _
			"AND		cuuu.mamma = cuuuu.hast_id				"

rs.Open SQL, MinCon

Session("connemara_namn")=rs("namn")
utl = rs("utlatande")
ovr = rs("ovrigt")
%>

Hur ska det "översättas" till det B-one säger att det ska vara?
Kan tyvärr för lite för att fixa detta själv :(
:OO

Medlem sedan sep. 2003301 inlägg
#5

Hmm gaaah !
Hur ser SQL satsen ut.

Response.Write SQL
Response.End

Medlem sedan juni 2005264 inlägg
#6

Fraggel skrev:

Hmm gaaah !
Hur ser SQL satsen ut.

Response.Write SQL
Response.End

Jag vet inte... :(

Har varit inne och ändrat lite, nu säger den

Error Type:
ADODB.Recordset.1 (0x800A0BB9)
The application is using arguments that are of the wrong type, are out of acceptable range, or are in conflict with one another.
/databas/hast.asp, line 24

Rad 24: objRS.Open"[QUERY]", objConn, 3,3

Här är lite mer kod

<HTML>
<META NAME="Author" CONTENT="©Sophie Larsson &amp; Karin Halvarsson 2005">
<META NAME="robots" CONTENT="noindex">
<link href="stil.css" rel="stylesheet" type="text/css">

<TITLE>Aramennoc.se - Med connemaran i focus</TITLE>

<BODY BGCOLOR="#FFFFFF">

<%
hast_id = Request.Querystring("hast_id")

Dim objConn
Dim objRS
Set objRS = Server.CreateObject("ADODB.Recordset")
Set objConn = Server.Createobject("ADODB.Connection")

objConn.ConnectionString="DRIVER={MySQL};SERVER=localhost;DATABASE=aramennoc_se;UID=aramennoc_se;PWD=xxxxxxxxxxx;"
objConn.Open

objRS.Open"[QUERY]", objConn, 3,3
%>

<%
SQL	 = 		"SELECT 	c.namn,										" & _
			"			c.kon,										" & _
			"			c.reg_nr,									" & _
			"			c.stamboks_nr,								" & _
			"			c.ras,										" & _
			"			c.fodd,										" & _
			"			c.dod,										" & _
			"			c.farg,										" & _
			"			c.tecken,									" & _
			"			c.mankhojd,									" & _
			"			c.uppfodare, 								" & _
			"			c.inskickad_av,								" & _
			"			c.inskickad_av_mail,						" & _
			"			c.ovrigt,									" & _
			"			c.premierad,								" & _
			"			c.utlatande,								" & _
			"			c.verksam,									" & _
			"			c.imp,										" & _
			"			c.exp,										" & _
			"			c.utlstbnr,									" & _
			"			c.bild,										" & _
			"			ce.namn 		AS e,						" & _
			"			ce.hast_id 		AS e_id,					" & _
			"			cu.namn	 		AS u,						" & _
			"			cu.hast_id 		AS u_id,					" & _
			"			cee.namn	 	AS ee,						" & _
			"			cee.hast_id 	AS ee_id,					" & _
			"			ceu.namn	 	AS eu,						" & _
			"			ceu.hast_id 	AS eu_id,					" & _
			"			cue.namn	 	AS ue,						" & _
			"			cue.hast_id 	AS ue_id,					" & _
			"			cuu.namn	 	AS uu,						" & _
			"			cuu.hast_id 	AS uu_id,					" & _
			"			ceee.namn	 	AS eee,						" & _
			"			ceee.hast_id 	AS eee_id,					" & _
			"			ceeu.namn	 	AS eeu,						" & _
			"			ceeu.hast_id 	AS eeu_id,					" & _
			"			ceue.namn	 	AS eue,						" & _
			"			ceue.hast_id 	AS eue_id,					" & _
			"			ceuu.namn	 	AS euu,						" & _
			"			ceuu.hast_id 	AS euu_id,					" & _
			"			cuee.namn	 	AS uee,						" & _
			"			huee.hast_id 	AS uee_id,					" & _
			"			cueu.namn	 	AS ueu,						" & _
			"			cueu.hast_id 	AS ueu_id,					" & _
			"			cuue.namn	 	AS uue,						" & _
			"			cuue.hast_id 	AS uue_id,					" & _
			"			cuuu.namn	 	AS uuu,						" & _
			"			cuuu.hast_id 	AS uuu_id,					" & _
			"			ceeee.namn	 	AS eeee,					" & _
			"			ceeee.hast_id 	AS eeee_id,					" & _
			"			ceeeu.namn	 	AS eeeu,					" & _
			"			ceeeu.hast_id 	AS eeeu_id,					" & _
			"			ceeue.namn	 	AS eeue,					" & _
			"			ceeue.hast_id 	AS eeue_id,					" & _
			"			ceeuu.namn	 	AS eeuu,					" & _
			"			ceeuu.hast_id 	AS eeuu_id,					" & _
			"			ceuee.namn	 	AS euee,					" & _
			"			ceuee.hast_id 	AS euee_id,					" & _
			"			ceueu.namn	 	AS eueu,					" & _
			"			ceueu.hast_id 	AS eueu_id,					" & _
			"			ceuue.namn	 	AS euue,					" & _
			"			ceuue.hast_id 	AS euue_id,					" & _
			"			ceuuu.namn	 	AS euuu,					" & _
			"			ceuuu.hast_id 	AS euuu_id,					" & _
			"			cueee.namn	 	AS ueee,					" & _
			"			cueee.hast_id 	AS ueee_id,					" & _
			"			cueeu.namn	 	AS ueeu,					" & _
			"			cueeu.hast_id 	AS ueeu_id,					" & _
			"			cueue.namn	 	AS ueue,					" & _
			"			cueue.hast_id 	AS ueue_id,					" & _
			"			cueuu.namn	 	AS ueuu,					" & _
			"			cueuu.hast_id 	AS ueuu_id,					" & _
			"			cuuee.namn	 	AS uuee,					" & _
			"			cuuee.hast_id 	AS uuee_id,					" & _
			"			cuueu.namn	 	AS uueu,					" & _
			"			cuueu.hast_id 	AS uueu_id,					" & _
			"			cuuue.namn	 	AS uuue,					" & _
			"			cuuue.hast_id 	AS uuue_id,					" & _
			"			cuuuu.namn	 	AS uuuu,					" & _
			"			cuuuu.hast_id 	AS uuuu_id					" & _
			"FROM 		connemara c,									" & _
			"			connemara ce, 									" & _
			"			connemara cu, 									" & _
			"			connemara cee, 									" & _
			"			connemara ceu, 									" & _
			"			connemara cue, 									" & _
			"			connemara cuu, 									" & _
			"			connemara ceee, 								" & _
			"			connemara ceeu, 								" & _
			"			connemara ceue, 								" & _
			"			connemara ceuu,									" & _
			"			connemara cuee, 								" & _
			"			connemara cueu, 								" & _
			"			connemara cuue, 								" & _
			"			connemara cuuu, 								" & _
			"			connemara ceeee, 								" & _
			"			connemara ceeeu, 								" & _
			"			connemara ceeue, 								" & _
			"			connemara ceeuu, 								" & _
			"			connemara ceuee, 								" & _
			"			connemara ceueu, 								" & _
			"			connemara ceuue, 								" & _
			"			connemara ceuuu, 								" & _
			"			connemara cueee, 								" & _
			"			connemara cueeu, 								" & _
			"			connemara cueue, 								" & _
			"			connemara cueuu, 								" & _
			"			connemara cuuee, 								" & _
			"			connemara cuueu, 								" & _
			"			connemara cuuue, 								" & _
			"			connemara cuuuu 								" & _
			"WHERE 	h.hast_id = "& hast_id &" 							" & _
			"AND		c.pappa = ce.hast_id							" & _
			"AND		c.mamma = cu.hast_id							" & _
			"AND		ce.pappa = cee.hast_id					" & _
			"AND		ce.mamma = ceu.hast_id					" & _
			"AND		cu.pappa = cue.hast_id					" & _
			"AND		cu.mamma = cuu.hast_id					" & _
			"AND		cee.pappa = ceee.hast_id				" & _
			"AND		cee.mamma = ceeu.hast_id				" & _
			"AND		ceu.pappa = ceue.hast_id				" & _
			"AND		ceu.mamma = ceuu.hast_id				" & _
			"AND		cue.pappa = cuee.hast_id				" & _
			"AND		cue.mamma = cueu.hast_id				" & _
			"AND		cuu.pappa = cuue.hast_id				" & _
			"AND		cuu.mamma = cuuu.hast_id				" & _
			"AND		ceee.pappa = ceeee.hast_id				" & _
			"AND		ceee.mamma = ceeeu.hast_id				" & _
			"AND		ceeu.pappa = ceeue.hast_id				" & _
			"AND		ceeu.mamma = ceeuu.hast_id				" & _
			"AND		ceue.pappa = ceuee.hast_id				" & _
			"AND		ceue.mamma = ceueu.hast_id				" & _
			"AND		ceuu.pappa = ceuue.hast_id				" & _
			"AND		ceuu.mamma = ceuuu.hast_id				" & _
			"AND		cuee.pappa = cueee.hast_id				" & _
			"AND		cuee.mamma = cueeu.hast_id				" & _
			"AND		cueu.pappa = cueue.hast_id				" & _
			"AND		cueu.mamma = cueuu.hast_id				" & _
			"AND		cuue.pappa = cuuee.hast_id				" & _
			"AND		cuue.mamma = cuueu.hast_id				" & _
			"AND		cuuu.pappa = cuuue.hast_id				" & _
			"AND		cuuu.mamma = cuuuu.hast_id				"

objRS.Open SQL, MinCon

Session("connemara_namn")=rs("namn")
utl = rs("utlatande")
ovr = rs("ovrigt")
%>

<SPAN CLASS="stor"><%=(rs("namn"))%></SPAN>
<SPAN CLASS="normal">

<%
IF (rs("reg_nr"))<>"" THEN %>
<BR>(<%=rs("reg_nr")%>)
<%
END IF %>

<%
IF (rs("fodd"))<>"" OR (rs("uppfodare"))<>"" THEN %>
<BR>Född&nbsp;<%
IF (rs("fodd"))<>"" THEN %><%=rs("fodd")%>&nbsp;<% END IF %><% IF (rs("uppfodare"))<>"" THEN %><%=rs("uppfodare")%><% END IF %><% END IF %>

<BR><%=rs("kon")%>

<% IF (rs("farg"))<>"" THEN %>,&nbsp;<%=rs("farg")%><% END IF %>
<% IF (rs("tecken"))<>"" THEN %>,&nbsp;<%=rs("tecken")%><% END IF %>
<% IF (rs("mankhojd"))<>"0" AND (rs("mankhojd"))<>"" THEN %>,&nbsp;<%=rs("mankhojd")%>&nbsp;cm<% END IF %>

<BR>
<%
IF (rs("premierad"))<>"" THEN %>
<%=rs("premierad")%>.&nbsp;
<%
END IF %>
<%
IF (rs("verksam"))<>"" THEN %>
Pr.&nbsp;<%=(rs("verksam"))%>.
<%
END IF %>

<%
IF (rs("imp"))<>"" OR (rs("exp"))<>"" THEN %>
<BR>
<%
IF (rs("imp"))<>"" THEN %>
Importerad:&nbsp;<%=(rs("imp"))%>
<%
END IF %>

<%
IF (rs("exp"))<>"" THEN %>
&nbsp;Exporterad:&nbsp;<%=(rs("exp"))%>
<%
END IF %>
<%
END IF %>

<%
IF (rs("bild"))<>"" THEN %>
 <BR><BR>
<IMG SRC="bilder/<%=(rs("bild"))%>"><BR>
<%
END IF %>
  <BR>
</SPAN>

<%
IF utl<>"" THEN %>
<BR>
<TABLE WIDTH="500" CELLPADDING="0" CELLSPACING="0" BORDERCOLOR="#111111" class="normal" STYLE="border-collapse: collapse">
<TR>
<TD>
Utlåtande: <%=utl%>
Medlem sedan sep. 2003301 inlägg
#7

INNAN du försöker execvera din SQL sats läägg till dessa rader...

Response.Write SQL  ' Skriver SQL satsen på skärmen
Response.End          ' Stoppar dokumentet...
Medlem sedan jan. 2005296 inlägg
#8

Hehe den där sidan du kopiera ser inget vidare bra ut att jobba på, koden ser ju makalös ut :P

Har du kanske en adress till sidan så man kan kolla vilka funktioner det finns osv, så man kan kolla om det skulle vara svårt att börja om den från grunden.

Mvh //Dashi

Medlem sedan juni 2005264 inlägg
#9

Fraggel skrev:

INNAN du försöker execvera din SQL sats läägg till dessa rader...

Response.Write SQL  ' Skriver SQL satsen på skärmen
Response.End          ' Stoppar dokumentet...

Får fortfarande samma meddelande...

Medlem sedan sep. 2003301 inlägg
#10

lägger mig

Medlem sedan juni 2005264 inlägg
#11

Fraggel skrev:

lägger mig

Är lite trögfattad :l

Medlem sedan sep. 2003301 inlägg
#12

jag ger upp just nu...!

Medlem sedan juni 2005264 inlägg
#13

Dashi skrev:

Hehe den där sidan du kopiera ser inget vidare bra ut att jobba på, koden ser ju makalös ut :P

Har du kanske en adress till sidan så man kan kolla vilka funktioner det finns osv, så man kan kolla om det skulle vara svårt att börja om den från grunden.

Mvh //Dashi

https://www.haststam.com
Här är direktlänk till sidan jag försöker göra http://www.haststam.com/raser/hast.asp?hast_id=26664

(annars väljer man ras i listan, klickar på sök och väljer en häst som kommer upp)

Medlem sedan jan. 2005296 inlägg
#14

Lorelie skrev:

https://www.haststam.com
Här är direktlänk till sidan jag försöker göra http://www.haststam.com/raser/hast.asp?hast_id=26664

(annars väljer man ras i listan, klickar på sök och väljer en häst som kommer upp)

den sidan såg rätt enkel ut, så jag föreslår att du sparar databasen om du behöver den och börjar om med sidan från grunde.. det går snabbare, är lättare och du lär dig samtidigt :)

Och behöver du hjälp på vägen så kan du ju söka efter exempel koder elr fråga här på webforum :P

Medlem sedan juni 2005264 inlägg
#15

Dashi skrev:

den sidan såg rätt enkel ut, så jag föreslår att du sparar databasen om du behöver den och börjar om med sidan från grunde.. det går snabbare, är lättare och du lär dig samtidigt :)

Och behöver du hjälp på vägen så kan du ju söka efter exempel koder elr fråga här på webforum :P

Jag har lyckast pilla ihop det hela nu :e Fast det är inte säkert jag får använda koden =( Kanske får göra allt från grunden ändå, och det kan jag inte =S

294 ms totalt · 4 externa anrop · v20260731065814-full.2f471f9e
130 ms — deklarationer (db)
0 ms — hämta statistik (cache)
161 ms — hämta tråd, inlägg och bilagor (db)
127 ms — ändringar (db)