Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

Sequential number generator


  • Please log in to reply
11 replies to this topic

#1 Bigjimmylaw

Bigjimmylaw

  • Members
  • 6 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:11:19 AM

Posted 18 June 2018 - 09:46 PM

I am needing a file created that I can put on a server so that I can just open the file and it gives me the next sequential number. I'm connecting two buildings and I need the file to be local so they can access it securely from only the two locations. Ideas?

BC AdBot (Login to Remove)

 


#2 Chris Cosgrove

Chris Cosgrove

  • Moderator
  • 6,728 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Scotland
  • Local time:04:19 PM

Posted 21 June 2018 - 05:55 PM

What exactly are you trying to achieve with this ?

 

If it's a matter of numerical sequence for documents and only two locations are involved how about one site uses odd numbers and the other even ones ?  You could then tell at a glance where any file originated.

 

Chris Cosgrove



#3 Bigjimmylaw

Bigjimmylaw
  • Topic Starter

  • Members
  • 6 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:11:19 AM

Posted 21 June 2018 - 05:58 PM

We are a volunteer fire station. We need to be able to assign the next run number to a report.

#4 rp88

rp88

  • Members
  • 3,016 posts
  • OFFLINE
  •  
  • Gender:Not Telling
  • Local time:03:19 PM

Posted 21 June 2018 - 06:43 PM

In effect what you are saying here is that whenever anyone tries to file some kind of report, whichever of your two buildings they are working from, you want to have some kind of system in place which inserts a number one larger than whatever number was on the previously filed report? And in theory your previously field report could have been done at either the station typing a report now, or the other station? I'm just checking that we've properly understood what you want.

 

Have you ever done any sort of programming? I'm wondering if a solution might be possible using a raspberry pi as a "server", not a server holding anything big or complex, just solely their to control the iterating of your numbers, and to send info back and forth from the buildings about what the most recently filed number is.

 

P.S. how often are you doing this. how many reports per year approximately, knowing this will be very important when it comes to choosing the form to store the number in so as to avoid integer overflow.


Back on this site, for a while anyway, been so busy the last year.

My systems:2 laptops, intel i3 processors, windows 8.1 installed on the hard-drive and linux mint 17.3 MATE installed to USB

#5 Bigjimmylaw

Bigjimmylaw
  • Topic Starter

  • Members
  • 6 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:11:19 AM

Posted 21 June 2018 - 06:46 PM

Currently we only have one station and we handwrite everything. We do about 600 runs per year. When we start the second station however, we can't use the system we have now

#6 rp88

rp88

  • Members
  • 3,016 posts
  • OFFLINE
  •  
  • Gender:Not Telling
  • Local time:03:19 PM

Posted 30 June 2018 - 05:39 PM

Could you state whether my understanding in post #4 is correct? The 600 runs figure is useful, you could go for many decades before having any difficulty with programmatic representations of that kind of number but I'm still unsure as to whether I've understood exactly what your current method is supposed to do, what are the desired inputs, outputs and processes. I'm also unsure what you do or do not know about programming and networking. In the absence of other information one wonders why you wouldn't just log all callouts at one station as StationA_X where X is your number and all from the other station as StationB_X. One also wonders if when automating the handwritten number iteration, due to the higher workload expected when operating two stations, might as well involve automating other aspects of whatever your process entails.

Edited by rp88, 30 June 2018 - 05:42 PM.

Back on this site, for a while anyway, been so busy the last year.

My systems:2 laptops, intel i3 processors, windows 8.1 installed on the hard-drive and linux mint 17.3 MATE installed to USB

#7 Bigjimmylaw

Bigjimmylaw
  • Topic Starter

  • Members
  • 6 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:11:19 AM

Posted 30 June 2018 - 05:48 PM

Could you state whether my understanding in post #4 is correct? The 600 runs figure is useful, you could go for many decades before having any difficulty with programmatic representations of that kind of number but I'm still unsure as to whether I've understood exactly what your current method is supposed to do, what are the desired inputs, outputs and processes. I'm also unsure what you do or do not know about programming and networking. In the absence of other information one wonders why you wouldn't just log all callouts at one station as StationA_X where X is your number and all from the other station as StationB_X. One also wonders if when automating the handwritten number iteration, due to the higher workload expected when operating two stations, might as well involve automating other aspects of whatever your process entails.



#8 Bigjimmylaw

Bigjimmylaw
  • Topic Starter

  • Members
  • 6 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:11:19 AM

Posted 30 June 2018 - 05:51 PM

Currently we just have pen and paper. We just write down the next number on the next page. Since we are adding a second station, we cannot continue with that system. I have no programming knowledge but I have networked the buildings together with a VPN and added a file server. We cannot take paperwork out of the building due to HIPPA restrictions and new town ordinances.

#9 britechguy

britechguy

    Been there, done that, got the T-shirt


  • Moderator
  • 8,140 posts
  • ONLINE
  •  
  • Gender:Male
  • Location:Staunton, VA
  • Local time:11:19 AM

Posted 30 June 2018 - 08:26 PM

Well, if the objective is strictly to have two locations able to grab, "the next number," such that they don't overlap one simple way to do that is via a spreadsheet under Google Docs, accessible to specific individuals at each site (or, if it's safe to be "way open" create a Google account that anyone that's part of the team can access), and always snag the next unused number from the spreadsheet.

 

Of course, I'd have other fields, too, like date, who snagged the number, etc., that need to be filled in by the snagger.

 

If you've been doing this by hand in one location, and pretty much plan on doing something entirely at one location or the other, other than needing sequence numbers shared by both, then you can use a spreadsheet that can be accessed by either location for that purpose.

 

Personally, I very much like the plan mentioned earlier where Station A would have only even numbers and Station B, odd.  Even better would be to make the sequence numbers "multi-part" much like an SSN.  Three digits for the station as the first three, followed by, for instance, YYYYMMDD-HHMM, snagged when the report is generated.  Codes make a lot more sense with fixed parts for whatever element could change or be expanded (e.g., station ID), but with something that can be generated without any concern for what any of the others have done for what follows it, and what that is can be determined based on your needs.  I just used YYYYMMDD-HHMM as an example because it's dead simple to acquire.


Brian  AKA  Bri the Tech Guy (website in my user profile) - Windows 10 Home, 64-Bit, Version 1803, Build 17134 

      Memory is a crazy woman that hoards rags and throws away food.

                    ~ Austin O'Malley

 

 

 

              

 


#10 Chris Cosgrove

Chris Cosgrove

  • Moderator
  • 6,728 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Scotland
  • Local time:04:19 PM

Posted 01 July 2018 - 05:59 PM

I am curious as to why this adminstrative problem is landing on your shoulders. I am familiar with the concept of volunter/ part-time firemen as we have them in the UK as a quick reaction team for smaller communities, but the stations and equipment are supplied and funded by the national fire service as are the administration systems.

 

You mention 'town ordnances' so presumably your local town or county or state system is responsible for your administration, so why are you having to do this ?

 

Chris Cosgrove



#11 Bigjimmylaw

Bigjimmylaw
  • Topic Starter

  • Members
  • 6 posts
  • OFFLINE
  •  
  • Gender:Male
  • Local time:11:19 AM

Posted 01 July 2018 - 06:42 PM

Our town is very small and independent. We have no IT department and I'm currently in college studying networking. I'm not real savvy with programming and things of that nature yet.  They will buy all of the stuff I need; just some things I look to learn such as this particular issue I have.



#12 Chris Cosgrove

Chris Cosgrove

  • Moderator
  • 6,728 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Scotland
  • Local time:04:19 PM

Posted 02 July 2018 - 06:26 PM

Fair enough and I appreciate your problems, I am currently trying to do some small scale circuit and PCB design, something I haven't done for about 25 years. Rusty or what ?

 

Your answer then is to keep the solution as simple as possible. If my 'odds and evens' suggestion is too simplistic for your requirements then seriously have a look at Google Documents as suggested by Brian. This can be set up from entirely private - one user only - all the way through to quite large groups having access to all the documents in the system. Google's help isn't bad either, they do after all want you to use their 'cloud'.

 

While this will mean that your record makers will have to move away from 'pen and paper' to using computers, and this may call for some training, it will not call for any programming skills on your part.

 

Chris Cosgrove






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users