p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

asp_databases thread: Eliminating unuseful information. Part 2


Message #1 by TL Jackson <actionjackson@a...> on Tue, 05 Dec 2000 01:32:12 -0500
Ricky and/or Everybody



I'm using your idea that you gave me earlier as you can tell below. Now, 

I'm having some problems that maybe you and others on here can help me. The 

following is the error I'm getting and following the error will be the code.



The Error: (comment after the error)

-------------------------------------------



AnnKearney-CookeAdults & Adolescents



Microsoft JET Database Engine error '80040e10'



No value given for one or more required parameters.



/doctorsearch2.asp, line 24



--------------------------------------------



As you can tell, I'm getting the first name, last name, and age range 

(AnnKearney-CookeAudlts & Adolescents) is the first loop in the code and 

sense there isn't any data in the database for the E-mail and Homepage 

address for this person it doesn't show up. So, I see that the first loop 

is working. The problem I think lies in the second loop. Right now, I'm not 

worrying about formatting the data which I will do when I get it up and 

running. See the code following.



The Code:

-------------------------------------------



<%

Dim objConn1

Dim objConn2

set objConn1 = Server.CreateObject("ADODB.Recordset")

set objConn2 = Server.CreateObject("ADODB.Recordset")

objConn1.Open "Select * from tblMembers", objConn

objConn1.MoveFirst

Do while NOT objConn1.EOF

Response.write objConn1("FName") & objConn1("LName")

Response.write objConn1("AgeRange")

Response.write objConn1("Email")

Response.write objConn1("HomepageURL")

objConn2.Open "Select * from tblSpecialties where 

tblSpecialties.PK_fk_UserId=" & objConn1("PK_UserId"), objConn

Do while NOT objConn2.EOF

Response.write objConn2("PK_fk_SpecialtyArea")

objConn2.MoveNext

Loop

objConn2.close

objConn1.MoveNext

Loop

objConn1.Close

Set objConn1=nothing



%>



--------------------------------------------------------



The primary keys in both my tblmembers table (objConn1) is "PK_UserId" and 

in my tblSpecialties table (objConn2) is "PK_fk_UserID". Please let me know 

if you need more information. Thanks for the help.



T.L.





At 04:48 PM 11/30/00 +0530, you wrote:

hi



oks let me assume few things

u have one table of members...which has doctor info.

other table havin speciality...

i guess they must be linkied by some doctorID or memberID.



if i would to do this thing here is how i will do it..



make 2 loops.



lets say 2 tables r named as members and speciality

and memberID is linkin the both tables.



rstmembers.open "Select * from members"



do while not rstmembers.EOF



DISPLAY MEMBER INFO



rstSpeciality.open "Select * from Speciality where

Speicality.MemberID=" & rstMembers("MemberID")



do while not rstSpeciality.EOF



DISPLAY MEMBERS SPECIALITIES

rstSpeciality.MoveNext



Loop



rstSpeciality.Close

rstMembers.MoveNext



Loop



I hope this should work



Ricky.







 > ----------

 > From: T.L. Jackson[SMTP:actionjackson@a...]

 > Reply To: ASP Web HowTo

 > Sent: Thursday, November 30, 2000 11:39 AM

 > To: ASP Web HowTo

 > Subject: [asp_web_howto] Eliminating unuseful information.

 >

 > Hello everybody, I'm new to the list here. For the past month I have been

 > looking for a way to eliminate a problem I'm having with my webpage that I

 > have created and could use some help. If you take a look at the following

 > URL at: http://www.cappnet.org/specialtysearch.asp You will notice how

 > the same doctor's information comes up over and over and the only change

 > in the information is the highlighted specialty area of the doctor. I'm

 > trying to only get the doctor's information to come up once with all their

 > specialty area with that information. How would I do that? In the

 > database, I set up three different tables. One is called

 > "lookupspecialty" which has the listing of specialty area. Then I have a

 > second table called "members" which has the doctor's information. Now,

 > the relationship is a one to many. One doctor can have many specialty

 > area. Everything I have tried to do isn't working and now I'm stuck

 > looking for answers. Can somebody help me? If so, please e-mail me at:

 > actionjackson@a... If you need more infomation please let me

 > know.

 >

 > Sincerely,

 >

 > T.L. Jackson

 > actionjackson@a...

 >





Message #2 by "Ken Schaefer" <ken@a...> on Wed, 6 Dec 2000 12:17:40 +1100
http://www.adopenstatic.com/faq/80040e10.asp



All about 80040e10 errors and their likely causes.



Cheers

Ken



----- Original Message -----

From: "TL Jackson" <actionjackson@a...>

To: "ASP Databases" <asp_databases@p...>

Sent: Tuesday, December 05, 2000 5:32 PM

Subject: [asp_databases] Eliminating unuseful information. Part 2





> Ricky and/or Everybody

>

> I'm using your idea that you gave me earlier as you can tell below. Now,

> I'm having some problems that maybe you and others on here can help me.

The

> following is the error I'm getting and following the error will be the

code.

>

> The Error: (comment after the error)

> -------------------------------------------

>

> AnnKearney-CookeAdults & Adolescents

>

> Microsoft JET Database Engine error '80040e10'

>

> No value given for one or more required parameters.

>

> /doctorsearch2.asp, line 24

>

> --------------------------------------------

>

> As you can tell, I'm getting the first name, last name, and age range

> (AnnKearney-CookeAudlts & Adolescents) is the first loop in the code and

> sense there isn't any data in the database for the E-mail and Homepage

> address for this person it doesn't show up. So, I see that the first loop

> is working. The problem I think lies in the second loop. Right now, I'm

not

> worrying about formatting the data which I will do when I get it up and

> running. See the code following.

>

> The Code:

> -------------------------------------------






  Return to Index