problems with asp

S

shaz kahn

hi guys ive just started this forum and ASP programming and so far its
not too bad I was wondering if any one can help. Am creating a book
search website which sellers can add books to the database with their
details for users to contact them. Am trying to search from two tables
seller and books, where the users will enter a book title in a textbox
if that title exits it will display book title and seller's pnumber with
their e-mail and name. Please help me ive been working on this for weeks
without any result.
your response will be much appreciated.

i have two tables seller and books
book(table)
books
bookID
pnumberID
author
price
keyword
title etc..

seller(table)
bookID
pnumber
password
name
surname
email etc...
 
P

Paxton

shaz said:
hi guys ive just started this forum and ASP programming and so far its
not too bad I was wondering if any one can help. Am creating a book
search website which sellers can add books to the database with their
details for users to contact them. Am trying to search from two tables
seller and books, where the users will enter a book title in a textbox
if that title exits it will display book title and seller's pnumber with
their e-mail and name. Please help me ive been working on this for weeks
without any result.
your response will be much appreciated.

i have two tables seller and books
book(table)
books
bookID
pnumberID
author
price
keyword
title etc..

seller(table)
bookID
pnumber
password
name
surname
email etc...

Did your post get truncated? I don't see a question. What's the
problem you need help with?

/P.
 
P

Phillip Windell

shaz kahn said:
seller and books, where the users will enter a book title in a textbox
if that title exits it will display book title and seller's pnumber with
their e-mail and name.

It should have been asked in the "asp.db" group but,...

I would use better tables names and different fields. I would also use
naming conventions. Table names begin with "tbl", field names beging with
"fld".

tblBooks
fldBookID
fldPnumber
fldAuthor
fldPrice
fldTitle

tblAuthors
fldAuthorID
fldName
fldSurname
fldEmail
fldPassword
fldBookID

The SQL Statement might be something similar to this:
(I'm not an SQL or database expert)

SELECT
tblBooks.fldBookID,
tblBooks.fldTitle,
tblBooks.fldAuthorID,
tblAuthor.fldName,
tblAuthor.fldSurname,
tblAuthor.fldEmail
FROM
tblBooks
INNER JOIN
tblAuthor
ON
tblBooks.fldBookID = tblAuthor.fldBookID
WHERE
tblBooks.fldTitle
LIKE
%"some title name here"%

I recommend that you create a Parameterized Query (if using Access) or a
Stored Proceedure (if using SQL Server) and don't put raw SQL statements in
the ASP code.

And you should be asking this type of question in:
"microsoft.public.inetserver.asp.db"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,144
Messages
2,570,823
Members
47,369
Latest member
FTMZ

Latest Threads

Top