Hi i am having 3rd party csv file. i am having php uploading script to upload the datas into my table. while uploading datas into my mysql Table mean while it has to remove duplicate entries rows from CSV file. Please help me

Member Avatar
Member Avatar
+0 forum 21

Hello there ! I wrote a dll( using MINGW and Codeblocks ) that should do the "background work" of my app. I have an interface build in Microsoft Visual C++ 2015. Is posible to control some TextBoxes, or Buttons( enable/disable ) or ProgressBars, or opening a new Form from the DLL ? Any code snippet would be really apreciated.

Member Avatar
+0 forum 0

Hi Group, I've imported an existing form into a new project that I'm creating (using Visual Studio 2015 Express/VB.net). When displaying the "Design" version (the user interface), it looks like a plain form and doesn't resemble the actual form in the original program. As per the directions, I added the existing item through the Solutions Explorer (Add > "Existing Item"). I added the programName.Designer.vb programName.resx programName.vb Where did I go wrong? What am I missing? In advance, thanks for your help. Don

Member Avatar
Member Avatar
+0 forum 1

Fair warning - I'm still learning so this might be a very newb like question: What I'm trying to do: I'm trying to import a python file into a Tkinter window and run it when I press a button. Eventually I'd like to display the output of the imported script (yahooKeyStats) into a separate window and then save it to a text file but I am still learning how to do that The current issue: When I import "yahooKeyStats" then convert it to tsx for use within this script the yahooKeyStats module seems to run before the tkinter window is …

Member Avatar
Member Avatar
+0 forum 2

Hi all! Whenever I am working with my code in my main.cpp file, I can call character-handling functions like * isdigit * isalpha * isspace * toupper without importing the `cctype` library. However, my C++ How to Program Book shows that the cctype library must be imported before the functions can be used. Why and how am I able to access these (working) functions without importing the cctype library in my main.cpp file?

Member Avatar
Member Avatar
+0 forum 7

This is a PyEditor I made because I couldn't get a IDLE working on windows 95.

Member Avatar
Member Avatar
+0 forum 14

I uploaded a module named [symboldict](https://pypi.python.org/pypi/symboldict) to the python package index (pypi). This snippet shows how to use it to create a dictionary of symbols from various modules. This dictionary can be used as a common language shared by several modules. It can be used to load python libraries in a lazy way. It also brings the power of python dictionaries to manipulate collections of functions.

Member Avatar
Member Avatar
+4 forum 1

Hi fellow members of Daniweb. I've been working on project for the past few days now, and have come across a bump, that i am unable to pass. The project, when finished, will do the following: 1. Select DBF file from computer location (Default C:) 2. Import the database file into a DataGridView 3. Export the Datagridview into a file type of choice (For the meantime it will be an .XSLX file) Now i know there are many software out there that do this already, however i require this one for unique capabilities within my workplace. Currently, i can open …

Member Avatar
Member Avatar
+0 forum 4

hi, i have an import csv script but it does not get entered into the database. only "uploaded successfully" and the data is echoed but nothing in the database is something wrong with it? and is it sql injection safe? <?php if(isset($_SESSION['sess_user_id'])) { if (isset($_POST['ubmit'])) { require "connection.php"; $session = $_SESSION['sess_user_id']; if (is_uploaded_file($_FILES['csv']['tmp_name'])) { echo "<h1>" . "File ". $_FILES['csv']['name'] ." uploaded successfully." . "</h1>"; echo "<h2>Displaying contents:</h2>"; readfile($_FILES['csv']['tmp_name']); } //Import uploaded file to Database $handle = fopen($_FILES['csv']['tmp_name'], "r"); $import=$dbh->prepare("INSERT INTO contact1( user_id, salutation, fname, lname, dob, house, mobile, office, email, spouse_name) VALUES(?,?,?,?,?,?,?,?,?,?"); while (($data = fgetcsv($handle, 1000, ",")) !== …

Member Avatar
Member Avatar
+0 forum 10

Controller: $data['error'] = ''; //initialize image upload error array to empty $config['upload_path'] = './uploads/'; $config['allowed_types'] = 'csv'; $config['max_size'] = '10000'; $this->load->library('upload', $config); // If upload failed, display error if (!$this->upload->do_upload()) { $data['error'] = $this->upload->display_errors(); $data['mainpage']='category'; $data['mode']='addcsv'; $this->load->view('includes/mainpage',$data); //Category Id Category Name Sub-category Id Sub-category Name } else { $file_data = $this->upload->data(); $file_path = './uploads/'.$file_data['file_name']; // $cformat[0]="Category Id"; // $cformat[1]="OrderName"; // $cformat[2]="Relevancy"; // $cformat[3]="Feedback"; if ($this->csvimport->get_array($file_path)) { $csv_array = $this->csvimport->get_array($file_path); foreach ($csv_array as $row) { $excel=array(); $cat_id=$row('Category Id'); $name=$row('Category Name'); $que= "INSERT INTO category (Caegory Id,Category Name) VALUES ('$cat_id','$name')"; $excel=$que; $this->bulkupload_model->insert_csv($excel); } $this->flash->success('<h4>Csv Data Imported Successfully.</h4>'); redirect(base_url().'uploads/index'); } else $data['error'] = …

Member Avatar
Member Avatar
+0 forum 1

I'm trying to create a .txt reader and inserting the read data to the cleansheets software we are editing in class but instead of putting the correct data it does nothing. I made some prints and this is what I obtain: D:\Documentos\Desktop\ImportTest.txt cacacaca ----- [[Ljava.lang.String;@73a175] cacacaca ----- [[Ljava.lang.String;@73a175, [Ljava.lang.String;@364cf2] cacacaca ----- [[Ljava.lang.String;@73a175, [Ljava.lang.String;@364cf2, [Ljava.lang.String;@5f3215] cacacaca ----- [[Ljava.lang.String;@73a175, [Ljava.lang.String;@364cf2, [Ljava.lang.String;@5f3215, [Ljava.lang.String;@5a421d] cacacaca ----- [[Ljava.lang.String;@73a175, [Ljava.lang.String;@364cf2, [Ljava.lang.String;@5f3215, [Ljava.lang.String;@5a421d, [Ljava.lang.String;@1f528ea] cacacaca ----- [[Ljava.lang.String;@73a175, [Ljava.lang.String;@364cf2, [Ljava.lang.String;@5f3215, [Ljava.lang.String;@5a421d, [Ljava.lang.String;@1f528ea, [Ljava.lang.String;@12aa4ba] cacacaca ----- [[Ljava.lang.String;@73a175, [Ljava.lang.String;@364cf2, [Ljava.lang.String;@5f3215, [Ljava.lang.String;@5a421d, [Ljava.lang.String;@1f528ea, [Ljava.lang.String;@12aa4ba, [Ljava.lang.String;@e4e190] cocococo ----- [[Ljava.lang.String;@a011bb cocococo ----- [[Ljava.lang.String;@a011bb cocococo ----- [[Ljava.lang.String;@a011bb cocococo ----- [[Ljava.lang.String;@a011bb cocococo ----- [[Ljava.lang.String;@a011bb cocococo …

Member Avatar
Member Avatar
+0 forum 2

Hi, Im making a simple program which converts a encrypted text file the upload it to sql CE. This is time in and out logs of every employee. The date is extracted from a machine and downloaded as encrypted file. We managed to decrypt it by getting the equivalent value of each character. I need to decrypt this file then save it to database (sql server 2008 r2) Downloaded file looks like this, in plain text: ±²®ªÇª®°­°®­°®¯±ª®·¸²®¸±²B ´µ³ªÇª®°­°®­°®¯±ª®·¸²±¸³®N ´µ³ªÍª®°­°¯­°®¯±ª¯·¸®°¸²²T ±²®ªÍª®°­°¯­°®¯±ª°®¸®®¸°®9 ±¯´ªÍª®°­°¯­°®¯±ª°®¸®®¸±²A ´µ³ªÇª®°­°°­°®¯±ª®·¸±¶¸±´X ±¯´ªÇª®°­°°­°®¯±ª¯®¸²¯¸²´C ±²®ªÇª®°­°°­°®¯±ª¯®¸²±¸°µA ´µ³ªÍª®°­°°­°®¯±ª¯·¸±¶¸±²] ´µ³ªÇª®°­°³­°®¯±ª®·¸³¯¸²µX My code for now in uploading: (I used openfiledialog object to open the file) …

Member Avatar
Member Avatar
+0 forum 9

I am importing data from an excel worksheet in to a sql table, one of the columns in the table is set to nvarchar(50), the data i am importing are barcodes, but the problem i am having is the column is changing the data for example the number "5900397732209" is converted to "5.9004e+012" this is only happening when the data is imported. if i save the barcode direct from my software it shows in the correct format in the table. anyone know why this is.

Member Avatar
Member Avatar
+0 forum 4

hey guys so ive been asked to add an import csv function to my contacts page. <?php require "connection.php"; if ($_FILES[csv][size] > 0) { //get the csv file $file = $_FILES[csv][tmp_name]; $handle = fopen($file,"r"); if ($data[0]) { mysql_query("INSERT INTO contact (fname,lname,email) VALUES ( '".addslashes($data[0])."', '".addslashes($data[1])."', '".addslashes($data[2])."' ) "); } } while ($data = fgetcsv($handle,1000,",","'")); } ?> i found this coding on the net and just want some clarification. 1. `if($data[0])` checks if the first "column" of a csv file exists? 2. stumbled on a site that said `addslashes` isnt good but did not elaborat. why isnt it good? 3. say …

Member Avatar
+0 forum 0

Hi I got this error ImportError: No module named Crypto.Cipher Where can I find the module for windows and debian linux? How can I fix error both in windows and Linux? importerror no module named crypto.cipher windows Traceback (most recent call last): File "C:\Users\Win/\Desktop\client.py", line 2, in <module> from Crypto.Cipher import AES ImportError: No module named Crypto.Cipher >>> Python 2.7.6 (default, Nov 10 2013, 19:24:18) [MSC v.1500 32 bit (Intel)] on win 32 Type "help", "copyright", "credits" or "license" for more information. >>> from Crypto.Cipher import AES Traceback (most recent call last): File "<stdin>", line 1, in <module> ImportError: No …

Member Avatar
Member Avatar
+0 forum 2

Hi.. I really don't know what to do with my Program, it is needed to have a excel file on MDI Form, But i really don't how to. Can somebody help! Highly Appreciated. : ) Thanks! :)

Member Avatar
Member Avatar
+0 forum 1

I have some code that I edited for importing csv into mysql using PDO to bind parameters. I thought it was working before, but tested it again and the issue I have is that only one line (the fourth line) of the csv file is getting imported. The first line is the header which are the table field names. The first method below is what's used to parse the csv files and bind the field names with the data. The second method, loops through. I need another pair of eyes, so if anyone can help me figure out my issue, …

Member Avatar
Member Avatar
+0 forum 2

I've noticed when watching videos, usually people import everything. Such as `import javax.swing.*;`. So my question is, is it better to Import everything? Or only the things you need indiviually? I've heard it slows down your program if you import alot of things, is this true?

Member Avatar
Member Avatar
+0 forum 9

Hi everyone, I've Nokia Lumia 820 and i'm not able import contacts from SIM to the phone. Help me! Thank You

Member Avatar
Member Avatar
+0 forum 2

hi! i am creating a program that need to import excel file. i really don't know how to. Can someone help? Thanks in Advance! God Bless!

Member Avatar
Member Avatar
+0 forum 2

So I have been working on a directory and have not really been able to get it off the ground. As a matter of fact none at all. import H:\Python Helpful Programs\DivisibleBy.py (also: everything is in the same folder) I have also tried just DivisibleBy.py and some others. The error returned is that "EOL while scanning string literal" Any tips or ideas?

Member Avatar
Member Avatar
+0 forum 3

Hello guys, i have been working on a new script that will import data from a TXT file to mysql. Using this code works ok: $sql = 'LOAD DATA LOCAL INFILE 'logons-16-12-2013.txt' INTO TABLE pcvsuser COLUMNS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' LINES TERMINATED BY '\\r\\n''; But if i use this it does not work: $sql = "LOAD DATA LOCAL INFILE '".$file."' INTO TABLE pcvsuser COLUMNS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '\"' LINES TERMINATED BY '\\r\\n'"; Now i will show the entire code: <?php // Import shared data include 'config_all.php'; // Connect to Mysql server $con = mysql_connect("$sqlhost","$sqluser",""); …

Member Avatar
Member Avatar
+0 forum 11

Hi Everybody I have to import excel data in MySQL table, I know how to do this for simple excel data to 1 MySQL table. Here also I need to import data from excel to 1 table but data is provided in 1 form which needs to be converted first and then import, this is where I am trapped. Excel File - studentsmarks.xls - Exam_Name **Student_Registation_No Marks_Obtained** Subject HALF YEARLY 201 51 ENGLISH HALF YEARLY 201 67 ECONOMICS HALF YEARLY 201 68 HISTORY HALF YEARLY 202 45 ENGLISH HALF YEARLY 202 64 ECONOMICS HALF YEARLY 202 59 HISTORY I only …

Member Avatar
Member Avatar
+0 forum 4

I'm having trouble calling a function I've written after importing the module containing it. The module is called funky.py. Here is the code for funky.py: from ftplib import FTP_TLS #### FUNCTION --- fileup() #### for sending file via FTP TLS ## ## arg1 .. destname > the filename to be created on the destination machine ## arg2 .. sourcepath > the absolute path to the source file ## usage .... fileup('foobar.txt', 'C:/dir1/dir2/orig_foobar.txt', '123.45.678.90', 'myusernm', 'mypassword') ## Note 1. Will overwrite on destination if file already exists ## def fileup(destfile, sourcepath, host, uname, password ): # open FTP connection ftps = …

Member Avatar
Member Avatar
+0 forum 3

I am creating a software for my company in C#. The working process is like this. 1: we write information in an Excel file. 2: Then we go to the website (Company's customer support page) there is only one search box. and we search after appropriate information. it gives us result with all information. we need only information from the "summary column" and we write it down in the Excel file. what i am trying to do is creating a tool that will loop through all the given information, search it and get results and get back and save into …

Member Avatar
Member Avatar
+0 forum 6

I would like to make a Export / Import buttons that will save/open files that contain listView data (ListView Items) Can someone tell me is there a way to do this?

Member Avatar
Member Avatar
+0 forum 6

Hello, I would appreciate some help to import data from a text file to a datagridview. If anyone could give me a hint to get started... The textfiles have the column name in the "[ ]" I would like to read the data after the [wp], [pos], [rad] blocks, the data inside [] is not needed in the datagridview. My problem is that I don't know where to start, If I need to read line by line, and strip the text after reading? Sample of textfile: [route] "350 Mongstad - Aasgard C" [wp] "H Graa" [pos] 605100.00 0042600.00 [rad] 1852.00 …

Member Avatar
Member Avatar
+0 forum 2

Hie everyone I have the below code on my console to import data from an excel sheet to a mySql database but unfortunately I am having an error which reads: NO CONNECTION TRYING TO RECONNECT.... ERROR 2005 (HY000): UNKNOWN MYSQL SERVER HOST '(ID,NAME):' (11001) ERROR: Can't connect to the server My command is as follows: LOAD DATA LOCAL INFILE `C:\\temp\\test.csv' INTO TABLE bd_george.test FIELDS TERMINATED BY `;' LINES TERMINATED BY `\r\n' (id,name);

Member Avatar
Member Avatar
+0 forum 2

I already have a php file that catches data from an uploaded CSV file to MySQL but the problem is, every time I upload the csv file, it duplicates the data into the MySQL What i really want is, if I uploaded the first csv file, and edit some data on the same file, it will UPDATE the MySQL data. But if there's a new entry it will ofcourse add.. <?php $conn = mysql_connect("localhost", "root", "") or die (mysql_error()); mysql_select_db("sbhs",$conn); if(isset($_POST['submit'])) { $file = $_FILES['file']['tmp_name']; $handle = fopen($file,"r"); while(($fileop = fgetcsv($handle,1000, ",")) !== false ) { $firstname = $fileop[0]; $lastname …

Member Avatar
Member Avatar
+0 forum 2

Hi, I was wondering how I might get data from a personal application form (name, address, phone, etc..) sent to me in an email into excel without having to retype or cut and paste. I am open to any idea, I have upcoming membership drive/update and would love to automate it even 50% would be helpful. Thank you

Member Avatar
Member Avatar
+0 forum 5

The End.