Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. MySQL
  4. how can I tranfer values from mssql to mysql

how can I tranfer values from mssql to mysql

Scheduled Pinned Locked Moved MySQL
phpdatabasemysqlsql-servertutorial
3 Posts 2 Posters 33 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    djhankypark
    wrote on last edited by
    #1

    Hi There I need to tranfer the values of a field in MSSQL to fields in MYSQL Basically I have a database table in MSSQL with the following fields: Artist Name Title Plays And in MYSQL table I have the same fields: Artist Name Title Plays I need to transfer the amount of plays from the MSSQL table to the table in MYSQL which at the moment is equal to zero. I thought maybe some sort of Loop statement in my PHP page but am not sure how to lay it out properly and/or how to check the artist name and song title against each other so I don't put the plays in against the wrong artists and song title fields. Thank you for any pointers or advice in advance. Regards Ray

    N 1 Reply Last reply
    0
    • D djhankypark

      Hi There I need to tranfer the values of a field in MSSQL to fields in MYSQL Basically I have a database table in MSSQL with the following fields: Artist Name Title Plays And in MYSQL table I have the same fields: Artist Name Title Plays I need to transfer the amount of plays from the MSSQL table to the table in MYSQL which at the moment is equal to zero. I thought maybe some sort of Loop statement in my PHP page but am not sure how to lay it out properly and/or how to check the artist name and song title against each other so I don't put the plays in against the wrong artists and song title fields. Thank you for any pointers or advice in advance. Regards Ray

      N Offline
      N Offline
      nuraGGupta
      wrote on last edited by
      #2

      We have got an export utility inbuilt with MSSQL 2005 version (Earlier version also having this functionality). Using this utility you can easily transfer table data from one DB to another. On the other hand, if you want to do it pro grammatically then, what you need to do is to create and instance of your mysql server and another instance of your mssql server. Now start reading all the data from MSSQL, put it in a datatable and then when all the rows are finished reading, start transferring them to the instance created of the MySQL table one by one, column by column. Remember that select statement needs to be run for both MySQL and MSSQl table in the start, so as the the table instance are same for both the table during data transfer.

      D 1 Reply Last reply
      0
      • N nuraGGupta

        We have got an export utility inbuilt with MSSQL 2005 version (Earlier version also having this functionality). Using this utility you can easily transfer table data from one DB to another. On the other hand, if you want to do it pro grammatically then, what you need to do is to create and instance of your mysql server and another instance of your mssql server. Now start reading all the data from MSSQL, put it in a datatable and then when all the rows are finished reading, start transferring them to the instance created of the MySQL table one by one, column by column. Remember that select statement needs to be run for both MySQL and MSSQl table in the start, so as the the table instance are same for both the table during data transfer.

        D Offline
        D Offline
        djhankypark
        wrote on last edited by
        #3

        Brilliant thank you very much, sorry so long in replying to your answer. That has helped sort things and I do have a similar question which I will post a new thread for. again thank you for your reply and help Regards Ray

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups