...

View Full Version : Simple numbering system



lansing
02-07-2006, 10:19 PM
Hello....I don't know were to start coding this, but I have search for this here & other forums. I want a number to advance by a set number of numbers based on another number. I am trying to make something like a order numbering system but it isn't for order numbers...it is for a ticket system. It is similar to a ordering system...I want the support ticket number to increase like 2 - 5 numbers from the support ticket number that was opened before this one.

Example: I open a support ticket & my ticket # is 5000 & then you open a support ticket. I want your ticket $ to be like 5002 or 5005.

I have random number generator script that was copied from a password script & it isn't what I need. I want to start the support ticket numbers at like 500 & increase from there. All this will be stored in the database so I need to make a query to seek out the last ticket number & just make this ticket number increase by 2 number? If so, how do I make this work.

marek_mar
02-07-2006, 10:37 PM
Im not sure you really need to do it like that.
Is there a particular reason why you can't number them from 1 incrementing by 1?

lansing
02-07-2006, 10:51 PM
Im not sure you really need to do it like that.
Is there a particular reason why you can't number them from 1 incrementing by 1?This is just what I had in mind. The main reason is that the site doesn't get a lot of visitors right now & with the ticket #'s jumping like that then it would seem like there is more traffic to the site.

Al_90
02-07-2006, 11:03 PM
$i = 0;
$i + 5;
print $i;or somthin along those lines

marek_mar
02-07-2006, 11:04 PM
I'm trying not to laugh...

Al_90
02-07-2006, 11:50 PM
I'm trying not to laugh...
i didnt even really read the post just skimmed it if you laughing at me.

lansing
02-08-2006, 12:02 AM
What is so funny? Is this possible?

fci
02-08-2006, 06:29 AM
sounds like a design flaw with what you want to do. if this is integrated with a db, you should have a ticket id, and then use relational tables to affiliate it with your ticket id. you could easily keep a count on the ticket row of the current associated tickets. if what I just said is already over your head then you will be having some trouble. anything is possible.

lansing
02-08-2006, 10:05 PM
sounds like a design flaw with what you want to do. if this is integrated with a db, you should have a ticket id, and then use relational tables to affiliate it with your ticket id. you could easily keep a count on the ticket row of the current associated tickets. if what I just said is already over your head then you will be having some trouble. anything is possible.I don't understand what you are saying. Can you simplify it? I haven't been coding in php with MySQL for too long...

raf
02-08-2006, 11:09 PM
I'm trying not to laugh...
just go ahead.

fast incrementing support tickets
= a lott of support is needed
= a lott of problems
!= a lott of trafic

but anyway. just use an autonumber-field for your ticketID and add an additional columns that you update to ticketID*2+125 or whatever



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum