Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3784498
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T11:23:11+00:00 2026-05-19T11:23:11+00:00

I have a file, which contains passwords/usernames: thomas 123 john 321 What would be

  • 0

I have a file, which contains passwords/usernames:

thomas 123
john 321

What would be the best way to identify lines and add to them contact information? Right in password file I dont want store, because the size of the file matters.. I thought to add an identifier string before records, like this:

[1]
thomas 123
[2]
john 321

What do you think? It is a good way to identify lines? If yes, how I can read out line after identifier [number]?

If I can read out, then in a second file I can store contact information.

[1]
email, etc
[2]
email etc

this is a config file of an offline app, sadly I cant change the structure of that file (max. change: add an identifier before lines) or use database.

Thank you so much,

Adrian

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T11:23:11+00:00Added an answer on May 19, 2026 at 11:23 am

    You could use a while loop that reads every other line as your id and every other line as your username and password; however, like what @zerkms said, you’re better off putting your energy into a tried and tested database.

    Learning to use a database will save you time in the future so that on each project you don’t have to figure out exactly how to manipulate a flat file.

    Reusable solutions enable and empower you to focus on your goal and your product, whatever that may be.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a file which contains lines of data in the following format: a11
I have a file which contains multiple lines of this format: Item A 62.7
I have text file which contains lines as mentioned below <property>PASSWORD_X_1</property> <property>PASSWORD_A_2</property> <property>PASSWORD_B_6</property> so
i have a file which contains a lot of update query and some other
I am using Ruby (1.9.3) and Rails (3.2.2). I have tasks file which contains
I have a JSON file which contains a pound symbol in it. This json
I have a JSON file which contains HTML content. I want to load it
I have a dotx file which contains placeholders to be replaced with DB values
I have a text file which contains data seperated by '|'. I need to
I have a txt file which contains a google adsense code block and I'm

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.