Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

After check out grab a number for DB and mark it as sold

Status
Not open for further replies.

sbayter

IS-IT--Management
Nov 14, 2002
95
CO
Hi,
I'm trying to create an e-commerce site and have almost completed it but I need to figure out one last thing.
This site is to sell software licenses.
The user would go it and download the free trial and then for a full version they would have to enter a license number.
There and only two programs and I have a list of licence numbers in a db with 3 columns, one is for the name of the software, the other the licence number and the last one that has a checkmark meaning if the license was sold or not.
I have finished with the shopping cart and everything using Cart32. Before buying it the user has to register, shop and then go to check out.
HERE IS WHAT I REALLY NEED.
I need than as soon as the user checks out the license number would appear on the screen and the third column in the DB is checked.
Any suggestion are very welcome.
Thanks in advance,


sbayter
 
In the 3rd colum instead of a check use a 1 or a 0. It's easier to read that way. When selecting which key to give them make your SQL statement like &quot;Select * where checked <> 1&quot; if 1 means its been bought already. And once it selects one just mark it with a 1.

I hope that points you in the right direction.
 
Thanks for the tip.
If I do that the query would give me a list all all the available licences.
How cart I make it so it gives me only one?


sbayter
 
It will return everything but you will only work with the first record unless you do a rs.movenext()

so it will always grap the first record.

*the rs in rs.movenext() is the name of your record set :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top