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 8151105
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T15:16:11+00:00 2026-06-06T15:16:11+00:00

So I am fairly new to android programming. I have a database and I

  • 0

So I am fairly new to android programming. I have a database and I want to be able to take the information from the database stored on the android device, store it in a .csv file, attach it to an email, and send it to the receiver. This is however my first time working with a .csv file and I want to make sure I am doing it right.

I looked at this page: Convert database .db file into .csv

But I am not sure the correct way to implement this using my current code, or even if this is what I am looking for.

I also tried using a bit of: OpenCSV

and noticed a section about dumping SQL into a .csv, would this be the best way to implement it? Any and all help and advice would be appreciated, thank you for your time!

  • 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-06-06T15:16:13+00:00Added an answer on June 6, 2026 at 3:16 pm

    If you are not too commited to attaching a csv file, it is really easy to just dump a big string into the body of an email, and send it to someone. You don’t have the issue of writing a local file and attaching it.

    When sending an email you can just add:

    emailIntent.putExtra(Intent.EXTRA_TEXT, emailBody);

    where emailBody is a big string that has your data in it.

    At least this might be an interim solution?

    Here is a little code that can send an email with a big string of text in it.

                  String emailSubject = " Sent from my Android";
            String emailBody = "";
    
    
            // create a big String that has your data in it called emailBody
    
            Intent i = new Intent(Intent.ACTION_SEND);
            i.setType("text/plain");
    
                               // send it to yourself for testing
            // i.putExtra(Intent.EXTRA_EMAIL , new
            // String[]{"myemailaddress@fortesting.com"});
    
            i.putExtra(Intent.EXTRA_SUBJECT, emailSubject);
            i.putExtra(Intent.EXTRA_TEXT, emailBody);
    
            try {
                startActivity(Intent.createChooser(i, "Send mail..."));
            } catch (android.content.ActivityNotFoundException ex) {
                Toast.makeText(HistoryActivity.this,
                        "There are no email clients installed.",
                        Toast.LENGTH_SHORT).show();
            }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have just began opengl programming in android and i am fairly new to
I'm fairly new to Android programming and to Java in general, but I have
So I'm fairly new to Android Development and Programming in general... I have a
I fairly new to programming for the Android platform and have some question about
I'm fairly new to Android programming, so this may be a simple question, but
I am fairly new to Android programming and was wondering how I can get
Ok, im fairly new to android but i have managed to teach myself the
Everything will be coming from JSON objects. I'm fairly new to android layouts, what
I am fairly new to Android development - coming from a WPF background. I
I am fairly new to Android programming, but I am getting pretty good at

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.