Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Page 1 of 3 123 LastLast
Results 1 to 15 of 38

Thread: My sql

  1. #1
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts

    My sql

    This statement can insert multiple date at once into php datebase actually 3 titles Smith but i need title,keywords and url.Also i need
    sort out date which i want put all at once in php datebase copy date from google and paste and sort out here.

    insert into search (id,title)
    ('id,'Smith'),
    ('id','Smith'),
    ('id','Smith');
    Last edited by Pearl_9; 03-31-2014 at 10:42 PM.

  • #2
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts

    My sql

    insert into search (id,title) values ('id','Smith'),
    ('John','Smith'),
    ('Michael','Smith'),
    ('Robert','Smith');

    This is statement.

  • #3
    Super Moderator
    Join Date
    May 2005
    Location
    Southern tip of Silicon Valley
    Posts
    2,877
    Thanks
    2
    Thanked 164 Times in 159 Posts
    I'm familiar with mysql database, access database, oracle database and several other databases, but I've never heard of a php database.

  • #4
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts

    My sql

    Quote Originally Posted by FishMonger View Post
    I'm familiar with mysql database, access database, oracle database and several other databases, but I've never heard of a php database.
    Pardon me mysql database.

  • #5
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts
    any help......

  • #6
    Regular Coder Linux_Sage's Avatar
    Join Date
    Mar 2014
    Location
    Sterling,VA
    Posts
    106
    Thanks
    0
    Thanked 10 Times in 10 Posts
    In order to do that you'd need a TABLE that has the columns you're referring to. Until then you won't be able to. Once those columns are added all you'd need to do is:

    insert into search (id,title, date, url) values
    ('id','Smith', '2010-01-01', 'www.blah.com') .... and then you know the rest.

    However this 'keywords' sounds like a concept that would need it's own table as it's a list of something. Then you'd need to set up some foreign keys to build relations to this search table. I highly suggest you pick up a book on databases to gain a better idea of the concepts used.

  • #7
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts

    my sql

    Quote Originally Posted by Linux_Sage View Post
    In order to do that you'd need a TABLE that has the columns you're referring to. Until then you won't be able to. Once those columns are added all you'd need to do is:

    insert into search (id,title, date, url) values
    ('id','Smith', '2010-01-01', 'www.blah.com') .... and then you know the rest.

    However this 'keywords' sounds like a concept that would need it's own table as it's a list of something. Then you'd need to set up some foreign keys to build relations to this search table. I highly suggest you pick up a book on databases to gain a better idea of the concepts used.




    This is ok but how right now sort out date which i have in word pad(1000,titles,descriptions,keywords and url) i want copy and paste here.is any way that i can avoid manually inserting all this date.

  • #8
    Regular Coder Linux_Sage's Avatar
    Join Date
    Mar 2014
    Location
    Sterling,VA
    Posts
    106
    Thanks
    0
    Thanked 10 Times in 10 Posts
    I don't understand what you're trying to say. You don't know how to sort by dates? A simple SELECT query with an ORDER BY would accomplish this.

    If you don't want to manually insert so many records then a script could work. Either Python, Perl, or PHP or even Ruby, whatever you want.

  • #9
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts

    My sql

    Quote Originally Posted by Linux_Sage View Post
    I don't understand what you're trying to say. You don't know how to sort by dates? A simple SELECT query with an ORDER BY would accomplish this.

    If you don't want to manually insert so many records then a script could work. Either Python, Perl, or PHP or even Ruby, whatever you want.








    Do you have skype.Can we talk over the skype for 5 minutes.

  • #10
    Super Moderator
    Join Date
    May 2005
    Location
    Southern tip of Silicon Valley
    Posts
    2,877
    Thanks
    2
    Thanked 164 Times in 159 Posts
    I'm guessing that part of the problem is that English is not your primary language, which is making it difficult for you to explain what you need. When you used the word 'date', I suspect that you meant to use the word 'data'.

    Are you saying that the data you want to insert into the database in currently in a csv text file?

    Please post the following info
    1) The output (wrapped with the code tags) of this sql statement: show create table tablename (replace 'tablename' with the actual name of your database table)

    2) Your text file as an attachment

    3) The php code your using to insert this data into the database


    If your data is in a properly formatted csv file, you could use a LOAD DATA INFILE statement to import the data into the database.
    Last edited by FishMonger; 04-01-2014 at 03:41 PM.

  • #11
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by FishMonger View Post
    I'm guessing that part of the problem is that English is not your primary language, which is making it difficult for you to explain what you need. When you used the word 'date', I suspect that you meant to use the word 'data'.

    Are you saying that the data you want to insert into the database in currently in a csv text file?

    Please post the following info
    1) The output (wrapped with the code tags) of this sql statement: show create table tablename (replace 'tablename' with the actual name of your database table)

    2) Your text file as an attachment

    3) The php code your using to insert this data into the database


    If your data is in a properly formatted csv file, you could use a LOAD DATA INFILE statement to import the data into the database.
    I tried load data in file (import options )like csv file but is said Invalid column count in CSV input on line 1.

  • #12
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts

    My sql

    Quote Originally Posted by FishMonger View Post
    I'm guessing that part of the problem is that English is not your primary language, which is making it difficult for you to explain what you need. When you used the word 'date', I suspect that you meant to use the word 'data'.

    Are you saying that the data you want to insert into the database in currently in a csv text file?

    Please post the following info
    1) The output (wrapped with the code tags) of this sql statement: show create table tablename (replace 'tablename' with the actual name of your database table)

    2) Your text file as an attachment

    3) The php code your using to insert this data into the database


    If your data is in a properly formatted csv file, you could use a LOAD DATA INFILE statement to import the data into the database.







    I tried load data in file (import options )like csv file but is said Invalid column count in CSV input on line 1.

  • #13
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts
    Any body have time to talk over the skype.

  • #14
    Super Moderator
    Join Date
    May 2005
    Location
    Southern tip of Silicon Valley
    Posts
    2,877
    Thanks
    2
    Thanked 164 Times in 159 Posts
    I don't skype.

  • #15
    Regular Coder
    Join Date
    Aug 2013
    Posts
    196
    Thanks
    14
    Thanked 0 Times in 0 Posts

    My sql

    Quote Originally Posted by FishMonger View Post
    I don't skype.







    I have been working for 6 months on this project and do have attention to finish this,it left just little work to get done this.So i need help here if this will work i will donate some money here.All help which i had i am getting error #1064.


  •  
    Page 1 of 3 123 LastLast

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •