Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    MYSQL


SuperbHosting.net have generously sponsored dedicated servers to ensure a reliable and scalable dedicated hosting solution for BigResource.com.





Migrate The Records


in my records, there are some japanese characters and when i migrate the records to mysql, the data became some string like ???????? instead showing the japanese character correctly




View Complete Forum Thread with Replies

Related Forum Messages:
Migrate DB From 5.0.51a To 5.1.30
It has a relatively large (17 table) database which is basically a custom made forum. It was made in MySQL 5.0.51a which at that time came as part of the WAMP5 server package for Windows.

It has been about a year since I worked on it. Foolishly, I did not keep hold of the WAMP5 package that I used.

I have downloaded the new WAMP5 package, which comes with MySQL 5.1.30.

At first, the old database was not visible to the new MySQL server version. On the old backup I have, the data was located in C:wampinmysqlmysql5.0.51adataaaron_forum. I have basically moved the aaron_forum directory to the new MySQL data directory at C:wampinmysqlmysql5.1.30data and it is now picked up by the new MySQL server installation... however... it doesn't contain any tables according to my PHP, or indeed to the MySQL server.

What is odd, is that it does actually display all 17 tables, but then when I try to open a table, it says that it doesn't exist. Quite interesting.

I wanted to know if there is a way to migrate the data from the 5.0.51a generated MySQL server to the new 5.1.30 server?

View Replies !
Migrate From 3.23 To 4.1
I'm trying to migrate our mysql 3.23 database files to 4.1, is there a tutorial for this? Do I just copy the MYI MYD, and frm files from the 3.23 data directory to 4.1 directory?

View Replies !
Migrate 4.1 To 4.0- Possible?
I am running a big Drupal site on Host B, which uses MySql 4.1.19. Host B sucks and I want to move to Host A. Except they are running MySql 4.0.27

How can I get my database to work? I tried using dbase from Host B on Host A and am getting syntax errors, preventing the tables from loading.

Quote:

MySQL said: Documentation
#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'DEFAULT CHARSET=latin1 AUTO_INCREMENT=1' at line 7

View Replies !
Migrate From Db2 To MySQL
send any documents for migrating from db2 to mySQL,
i dont have any knowledge in this regard.

View Replies !
Migrate Data
how I can migrate data from Access to MySQL. I would appreciate very much is anyone can share his/her experiences with me.

View Replies !
Migrate 5.0 Database
HI am working on a website with CMS and i am having few issues.
I did my database for the CMS and i used the v5.0. from my computer.
I did not know in first place that the company that hosts the website were using v3.23.55 on solaris 8
I cannot import the datadabe or create a database with collation utf8_unicode_ci.
it gives me a syntax error.

View Replies !
Migrate Only Differing Rows?
Im currently using 'mysqldump' to dump the entire contents of my local database to my remote database.

This was fine, but now the database is huge, so I would like to know if there is a MySQL command/statement that compares the two databases and then only uploads rows that have been updated on the local database.

Is this possible to do? I can do this through PHP in a loop, but this takes ages, and I have a feeling there is a much more efficient way to do it using SQL statements.

View Replies !
Migrate Oracle To MySql
I am looking for the best solution for migrating Oracle DB to MySql DB that are both on UNIX Sun Solaris 9 boxes.

I started out with Oracle Migration Workbench, MySql Query Browser, Administration kit, Oracle client and an intermediate PC.

Haven't had any luck. I am getting plugin errors even though I can ping the source machine and put the plugins in the plugins directory.

Has anyone done this before. And if so, where did get the info from or how did you do it?

View Replies !
Migrate Data From MSAccess To MySQL
I supposed this is a simple one, but here it is. How can i migrate date from MSAccess tables to MySQL tables?

View Replies !
Install To Find / Migrate Back Up Data
My server crashed and I backed up the DB files. I have reloaded MYSQL and it is running and copied the old db files back into a folder. how do I get MYSQL to see it as a database and work?

View Replies !
How Often Is Best To Create New Database, Migrate Data With Shared Hosting?
I have got a web site that I have ben working on since March, 2007. It is a news reporting web site. It is replacing an older web site.

I created a new database (it uses the MySQL database) last March when I started working on the new web site. I have migrated all of the news content from the old web site database to the new web site database.

I have a shared web hosting. It's my understanding that the hosting service provider fills up one server with databases then starts a new server with databases.

For example, the IP for the server that is hosting the current database for the new web site is 10.6.166.5

I just created a new database (the hosting allows you to have ten databases per shared hosting). The IP for the server for the recently created database for the new web site hosting is 10.6.166.92

If the servers are ordered sequentially there have been 87 new servers filled up with databases since last March (i.e. 10.6.166.92 recently created IP minus 10.6.166.5 March, 2007 IP equals 87 servers).

The problem with migrating the nine-month old database to the new database is that I have got over a thousand news stories and two thousand pictures stored in the database with the 10.6.166.5 IP address. I would have to copy and paste all of the data into the phpMyAdmin program or write a PHP script that would automate the process.

Is there any benefit to migrating the 10.6.166.5 March, 2007 IP database over to the more recently created 10.6.166.92 IP database? Would it be reasonable to expect the more recently created database to perform better over the next 12 to 18 months than the one created nine months ago?

View Replies !
Errors Get When Try To Migrate Form Mysql4 To Mysql5 Using Mysql Migration Tool
I am running mysql server 4.0. I have installed the mysql5.0 in the same server. When I try to migrate form mysql4 to mysql5 in the same server I get java heap space error. I was looking the google the change the java heap space. But did not get any thing. I am running with win2k and mysql4 and mysql5 with JVM installed with 512 MB Ram.

There for I tried some other way. Even I installed my sql 5 in some other server in LAN whitch has more RAM and then try to migrate form mysql4 to mysql5 though the LAN I get some strange error saying Code:

View Replies !
Selecting Records Belonging To Multiple Records Through Join Table
I have is 3 tables, 'categories', 'levels' and 'categories_levels', the 'categories_levels' table is a join table, with the `id`, `category_id` and `level_id` fields. Categories can belong to many different levels, so records in the join table might look like this (assuming that the category has an ID of 5)

id, category_id, level_id
1, 5, 1
2, 5, 2
3, 5, 3

So you can see that category 5 belongs to 3 different levels (1, 2, and 3).

On a web page, I've got a multiple select box, which allows a user to filter the categories depending on which levels they belong to. What I need a query to do is use that join table to find all categories which belong to the selected levels. Now for the tricky bit. Only the categories which belong to every single selected level should be displayed. So in the example above, if I select level 1, then category 5 will be displayed, but if I select levels 1 and 4, then category 5 should not be displayed, because although it does belong to level 1, it doesn't belong to level 4 as well.

View Replies !
Counting Records From Subsets Of Records Returned From Query
I am trying to figure out how to count a subset of the records returned from a query. I have a query that returns records that fit the criteria ....

View Replies !
Selecting From 1 Table Only Records That Match Multiple Records In Another
I am having trouble writing an SQL statement to select all the records in Table-A that have multiple corresponding records in Table-B that meet a requirement.

Example: .....

View Replies !
All Records From Table A - All Records From Table B - Join Alike Records
I am by no means a SQl Jedi as will be apparent by my question, but I
can usually figure out a select statement on my own. I have one today
though that really has me stumped. I am working in MySQlL 5.

In My first select statement I get all my records from Table B
SELECT
`table_A`.`ITEM`,
`table_A`.`DECSCRIPTION`,
`table_A`.`UM`,
`table_A`.`PHASE`,
`table_B`.`Qty`,
`table_B`.`Calc` as calculated
FROM
`table_A`
Inner Join `table_B` ON `req_itemlist`.`ITEM` = `table_B`.`ItemID`

In my second statement I get my records that match in this case phase
401 in Table B and all my Table A records for phase 401.

SELECT
`table_A`.`ITEM`,
`table_A`.`DECSCRIPTION`,
`table_A`.`UM`,
`table_A`.`PHASE`,
`table_B`.`Qty`,
`table_B`.`Calc` as calculated
FROM
`table_A`

Left Outer Join `table_B` ON `req_itemlist`.`ITEM` = `table_B`.`ItemID`
Where
table_A.PHASE In ('401' )

Now I need to combine the Data of both recordsets. I need EVERYTHING in
Table B, but I also need All Table A records that match the phase
selection....

Can I write this one query or do I need to use a Temp table?

View Replies !
Count Related Records, But Show Records With NO Related Records Also
cl_items
========
it_id (pk)
it_ownerid
it_name

cl_offers
========
off_id (pk)
off_itid (fk) -> to it_id
off_whoid

My query needs to output ALL of the records in cl_items AND still show how many offers are on each item (from cl_offers)

I can't get what I want through the GROUP BY because I want to show the records in cl_items which DO NOT have any offers on them yet also.

Is there any way to do this with mysql only?

View Replies !
Delete Records That Have No Related Records In Other Table
How do I delete all records in a table that have no related records in another table? I tried this:

delete from t1 where t1.id=t2.id and count(t2.id)=0;

but it says "Unknown table 't2' in where clause". What's wrong?

View Replies !
Migrate Mysql 3.23 To Mysql 5.0.26
i want to move the database from server a (mysql 3.23) to a new hardware (mysql 5.0.26).

What is the best way to do this?

Move the database files from server a to server b?

Export a dump from the server a database to server b database?

Can i use the migration tool from mysql?

View Replies !
Delete Records Without Matching Records
I have a one to many relationship in my database. I would like to delete records in one table if there are no matching records in another table.

View Replies !
Records
I have a mysql database running on Mysql version 3.23.53 on a Red Hat
Linux 7.2. In the database there is a single table with over 150,000
records. Unfortunately, the performance of that table is very poor,
comparing to other tables in the same database.

View Replies !
10.000.000 Records
I've got some experience building PHP/MySQL websites, but the databases in these websites never contained more than a couple of thousand records. Now I've been asked to build a website with a database containing a table with roughly 10 million records.This amount of records gives me the creeps, to tell you the truth.
It's simple records, containing just 2 columns. The only thing a script would have to do is check wether a code is in the database or not.
Can I use standard PHP scripting methods and SQL queries, or does this amount of records demand a totally different approach? I can imagine an application getting very slow when it has to work with a huge recordset like this. What do I have to consider before I decide to build this site (or not)?

View Replies !
Certain Records
Code:

insert into users (username, password, email) select user , ID, email from selex.empleados_selex

but i want to copy only the records where its status is "working"

something like:

insert into users (username, password, email) select user , ID, email from selex.empleados_selex WHERE status =´working`

View Replies !
Records 1 To 10, 10 To 20 Etc
im not sure how to do this or what to search for so any help would be great.
basically if i do a (select * from table) how do i get only the fiorst ten matches like records 1 to 10 then like on another page id have records 10 to 20. i thought i coudld use limit but when i do say

SELECT *
FROM `sale`
LIMIT 2 , 4

i get 4 results back instead of what i thought would have been results ows 2 to 4

View Replies !
Pf Records
Is it possible to specify the limit of records that can be entered in the table.

View Replies !
Get Records
I have one table (members) and a linked table (payments) and I trying to retrieve all the records in the members table that don't have a record in the payments table.The payments table is linked to the members table by memberId. Does anyone know how I would compare the two tables and bring back only the members that don't have a record in the payments table?

View Replies !
Records
I want to extract those values whose modificatio dates are few days older using the following sql
[SQL]
select status from note where mdate<=date_add(date('Y-m-d'),interval -2 day) and status='Selected' and id=$r[0];
[/SQL]
but the comparison 'mdate<=date_add(date('Y-m-d'),interval -2 day)' doing nothing. I have checked it in db. There is no error too. How to correct that?

View Replies !
40 Records
This is to gather a sample from the database.
I need to select 40 consecutive records every 1001st record.
So I would need records 1001-1040
and
records 2002-2041
and so on.
Anyone have a clue on how to write the query for this?

View Replies !
To Many Records
This query is getting me rows which dont = $cid can anyone tell me why? =x
Code:

"SELECT event.eventName, event.eventMonth, event.eventYear, exhibitor.standNum
FROM event, exhibitor
WHERE exhibitor.companyID = event.companyID AND exhibitor.companyID = '$cid'"

View Replies !
Records That Are Only From 3 Pm To 6 Pm
I have a field in my table called time which is a datetime field.

The format of the data is like these below:
2006-07-12 17:55:19
2006-07-11 16:31:34
......

I would like to get every records that are only from 3 pm to 6 pm. Is there any query where I can check for the hour of a datetime field?

View Replies !
Add Records (bug)
when a record is added, it adds 2 records instead of one. Code:

View Replies !
How To Get First And Last Records
i want to get the first record and last record using a single query?

is it possible?

View Replies !
Can't See Old Records
I really don't know much about mysql.
We have an hardware device performing bandwidht management which
we didn't even know it is using mysql until it was broken down.

After we solved the problem, we saw that the operationg system running in the device is linux (and old version) and the database is mysql.

The problem is that we can't see the old data eventhough when I
view the binary ISD file I can see the whole data including the olds.
But the management program doesn't show the old data. When I reenter new definitions from the management program, I can see that they are written into the ISD files. ISD files contains both old and new records but I can see the only new files.

Does that mean the index files are curropted?
If so, How can I recreate indexes or recover them?

View Replies !
Top 5 Records - ASP
I have an ASP application talking to a MySQL database. All works fine but:

1) I can't figure out how to select just the latest 5 records in a table.

2) SELECT LAST_INSERT_ID() doesn't work, it just returns 0.

3) I need to select the 'recordid' (held in the first field and is the PK) of the latest record.

View Replies !
No Records In DB
I connected to the DB like this:
Set rsP1000 = Server.CreateObject("ADODB.Recordset")
strSQL = "SELECT [G2P] FROM tblClients WHERE ClientID = '" & strID & "' AND GTime2 ='10:00a'"
rsP1000.Open strSQL, adoCon

I was wondering if the connection does not return any results, how do I display nothing. It keeps failing out because there is no record.

View Replies !
Searching For Records
eg search for records having same email address

select txtemail,count(txtemail) from `tbl_user` GROUP BY txtemail
having COUNT(txtemail)>1;

and it works, is that the best way?

View Replies !
Duplicating Records...
I have looked long n hard at the Insert Select as being the answer to my
need to create duplicate records. (Purpose is basically to allow someone to
create a duplicate of an existing email template then modify it). I have
tried all sorts of variations on:

INSERT INTO emaillist SELECT * FROM emaillist WHERE emailid = #url.emailid#
(inc trying IGNORE) but of course this throws an error over duplicate keys.

All I want to do is to take Record A, duplicate it and have a new key
assigned to it (the key is an autonumber field).

View Replies !
Last N Records By Some_id
Here is a problem I've encountered a few times lately:

Given

CREATE TABLE foo(
id INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
some_id INT NOT NULL,
ts TIMESTAMP NOT NULL
);

find the last (ordered by ts) N id's for each some_id, with N > 1.

Is this possible in "pure" (i.e. without application code) MySQL 4.1.x?

View Replies !
Orphan Records
Given this setup:

inventory.itemID

item.itemID
item.description

I want a list of item descriptions which do NOT have an inventory
record. Any ideas?I did this before in MS Access as I recall by making
a query of things with inventory only then excluding those but I can't
even recall how to do that now. I'm working with php/mysql now and had
some luck generating aql with Access but not for this one.

View Replies !
Duplicate Records
mysql> select id, student_first_name, student_last_name, email,
application_date, modification_date, unique_key from student where id
in (7268, 862);
+------+--------------------+-------------------+----------------------------+---------------------+---------------------+------------------+
| id | student_first_name | student_last_name | email
| application_date | modification_date | unique_key |
+------+--------------------+-------------------+----------------------------+---------------------+---------------------+------------------+
| 862 | Phil | Powell | phil@blah.com |
2006-02-27 00:00:00 | 2006-02-27 00:00:00 | dF0WByrCP0vACftA |
| 7268 | Phil | Powell | phil@blah.com |
2006-02-27 00:00:00 | 2006-02-27 00:00:00 | dF0WByrCP0vACftA |
+------+--------------------+-------------------+----------------------------+---------------------+---------------------+------------------+


I accidentally created duplicate records upon attempting to migrate
data from one server to another. You will have 2, 3 or more records
with every single field identical except for the ID. Best way to know
they're dumps is by "application_date" along with "unique_key".

View Replies !
Sql To Get Most Recent Records
How would I write the query for mySQL to get all the records in a table that
were written in tha last 10 minutes?

I have a timestamp field (fldTime) that automatically inserts the curent
time when the record is inserted, but I'm unsure how to write a query that
would only get records from the last 10 miniutes.

View Replies !
Setting Value For All Records
How would i go about populating a new column based on an existing column
pluse a bit of text.

i.e i have a column fldID which contains numerics 1,2,3,4 etc and i want to
poulate a column fldIMAGE with values 1.jpg, 2.jpg etc.

View Replies !
Getting Unique Records
How do i get a list of ids from one table that do not have the same ids in
another table?

View Replies !
Join Sum To Records
Am trying to get a list of all vacation time used by each employee
since 1-1-2002. I can do it with 2 separate queries. The first looks
like...

SELECT e.employee_pk, e.first_name, e.last_name,
a.rate,a.effective_date,
((((YEAR(CURRENT_DATE)-YEAR(effective_date))*12))+(MONTH(CURRENT_DATE)-MONTH(effective_date)))
AS month_count, ((((YEAR(CURRENT_DATE)-2002)*12))+(MONTH(CURRENT_DATE)-1))
AS max_count FROM employee e, hr_vacation_accrual a WHERE
e.employee_pk = a.employee_uid AND e.active=1 AND exempt_status != 'H'
AND exempt_status != 'C' ORDER BY e.last_name, a.effective_date

What the above is doing is getting the employee's name, their accrual
rate (we accrue at various numbers of hours per month based on
seniority), the date the new seniority kicks in, and the number of
months at this rate, as well as how many months there are since
1-1-2002. Code:

View Replies !
Lock Records
I need to know how to lock single records in a table. I have multiple users
logging on to a web site. I need to keep them from changing data on a
record at the same time.

View Replies !
Restricting Records
I run a hobby-based hall of fame. At the moment people send their stats
to me and I manually update the database, run the queries, and convert the
results to .pdf which is then put online.

I'm in the process of automating the procedure by changing to a .php website
with the Hall of Fame powered by a mysql database, but what I'm trying to
figure out is if each user has a unique username and password, is it
possible for the database to only allow them to update the records in table
X, Y and Z which their own username / password created (ie, they can't mess
with other players entries)?

I think I could do it by giving each user their own set of mini tables, but
that would make the queries horrendously complicated

View Replies !
Alphanumeric Records
I have a varchar field in a table of about 48000 records. The vast majority
of the values are strictly numeric, but some have a letter A-Z either
prepended or appended to them. I need a query to grab all records that are
numeric. I know I can:

SELECT *
FROM my_table
WHERE
col1 NOT LIKE '%A%' AND
col1 NOT LIKE '%B%' AND
....
col1 NOT LIKE '%z%';

There has to be a cleaner/easier way?

View Replies !

Copyright © 2005-08 www.BigResource.com, All rights reserved