PDA


View Full Version : vBulletin Forums Importer


Brian
09-07-2007, 01:15 PM
This script will allow you to import data from your vBulletin forums into vBadvanced Dynamics. It will import all threads, posts, ratings, and attachments. To use the script, simply upload the attached file into your forum/admincp directory, go to it in your browser, and follow the on-screen instructions there.

tfw2005
09-08-2007, 02:29 AM
Hey Brian,

I want to import threads to a second instance of Dynamics. I uploaded the file, chose forum, and it only gave me the option to install it to the first instance.

Any way to get that fixed?

Brian
09-08-2007, 03:30 PM
Sure thing. I've just updated the attachment above. If you'll download it again and then open it up in a text editor, you'll see this line now where you can change the instance prefix.
define('ADV_DYNA_PREFIX', 'adv_dyna');

tfw2005
09-08-2007, 07:13 PM
Thanks Brian,

Getting an error with the new file...


Database error in vBulletin 3.6.7:

Invalid SQL:
INSERT INTO vba_fict_entries_pages (entryid, pagetext, pagenumber, allowsmilie) VALUES (

(Lotsa Values)

MySQL Error : 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 '), (
112031,
'thread text..........' at line 766
Error Number : 1064
Date : Saturday, September 8th 2007 @ 05:07:19 PM
Script : ......./admincp/vba_dyna_import_vbposts.php?do=import
Referrer : ....../admincp/vba_dyna_import_vbposts.php?do=submitforums
IP Address :
Username : Me
Classname : vB_Database

tfw2005
09-08-2007, 07:21 PM
Did some research, seems it crapped out when it hit a thread that was moved, and still had a redirect in the forum I was importing from. When I deleted the redirect, worked fine.

Brian
09-09-2007, 02:49 PM
Doesn't seem like redirects should cause a problem like that. :/
I have updated the attachment above though so that redirects will not be included. Thanks for pointing out the problem!

Lionel
09-24-2007, 08:39 AM
The importer works beautifully. Unfortunately since I needed to move threads and not entire forums I had to do the additional step of creating a transit forum, then move threads to transit forums and import that transit forum.

rollinjunk
09-25-2007, 10:09 AM
i get this error {Your vBa Dynamics attachments folder is not writable. Please make sure that your '/var/www/vhosts/bapetalk2/subdomains/dev/httpdocs/dyna/attachments' folder on your server is chmod to 777. Once you have updated this you may refresh the page to resume the import.}

but i dont have an attachments files i have an attachment file how ever should i change something in the code?

rollinjunk
09-25-2007, 10:14 AM
I then got this

http://www.bapetalk2.com/uploads/import.png


and this is the error i got


Database error in vBulletin 3.6.2:

Invalid SQL:
INSERT INTO adv_dyna_entries (entryid, title, catid, userid, username, dateline, views, posts, iconid, valid, open, sticky, showsignature, votenum, votetotal, ipaddress) VALUES (
1,
'lookin\' good...',
3,
'4',
'johnnyblaze036',
'1170949274',
'36',
'0',
'0',
'1',
'1',
'0',
'0',
'0',
'0',
'208.196.60.42'
);

MySQL Error : Duplicate entry '1' for key 1
Error Number : 1062
Date : Tuesday, September 25th 2007 @ 08:10:34 AM
Script : http://dev.bapetalk2.com/admincp/vba_dyna_import_vbposts.php?do=import
Referrer : http://dev.bapetalk2.com/admincp/vba_dyna_import_vbposts.php?do=submitforums
IP Address : 66.108.233.115
Username : rollinjunk
Classname : vB_Database

Brian
09-25-2007, 01:17 PM
Sounds like you had already submitted some entries to vBa Dynamics, and you have some threads/posts with conflicting id's. If you'll run these queries through phpMyAdmin or your vBulletin Admin CP then it should clear out all of that data.

TRUNCATE adv_dyna_entries;
TRUNCATE adv_dyna_entries_pages;
TRUNCATE adv_dyna_attachments;
TRUNCATE adv_dyna_entryparsed;
TRUNCATE adv_dyna_posts;
TRUNCATE adv_dyna_rate;

rollinjunk
09-25-2007, 02:08 PM
brian is that an apple compatible product?

Brian
09-25-2007, 02:27 PM
The import script? As far as I'm aware there should not be any issues with a Mac.

NashChristian
01-06-2008, 04:20 AM
Brian,

I noticed that after using this importer (on secondary instances), when it advises me to update my counters and I use the provided link to the vba_dyna_admin_maintenance.php, that it will only update the counters of my primary instance. How can I get this to also update the counters of my secondary instances?

Is it possible to add the [define('ADV_DYNA_PREFIX', 'articles');] line, as you advised for the vba_dyna_import_vBposts.php? Is it done exactly the same way?

Thanks for the help!
Jeff

NashChristian
01-06-2008, 05:04 AM
Nevermind. I figured out how to do this through the AdminCP, in the Maintenance section for each individual instance.

Thanks!
Jeff

yemen
02-06-2008, 12:37 AM
Invalid SQL:
INSERT INTO adv_dyna_entries_pages (entryid, pagetext, pagenumber, allowsmilie) VALUES (





Error Number : 1064
Date : Wednesday, February 6th 2008 @ 04:33:38 AM
Script : http://www.cyemen.com/VB/admincp/vba_dyna_import_vbposts.php?do=import
Referrer : http://www.cyemen.com/VB/admincp/vba_dyna_import_vbposts.php?do=submitforums
IP Address : 90.148.113.237
Username : الوحيشي
Classname : vb_database

Brian
02-06-2008, 11:19 AM
Can you post the entire error?

yemen
02-06-2008, 11:27 PM
oK brian it works now done .

but I want to remove thise thread what I should do ?

lms
02-08-2008, 11:40 AM
I have the error:
Database error in vBulletin 3.6.8:

Invalid SQL:
INSERT INTO vB_adv_dyna_entries_pages (entryid, pagetext, pagenumber, allowsmilie) VALUES (
4211,
'[FONT=arial,sans-serif]\n<img alt=\"\" height=\"1\" width=\"1\">\n',

.....


1,
0
),
(
4238,
'',
1,

);

MySQL Error : 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 ')' at line 141
Error Number : 1064
Date : Friday, February 8th 2008 @ 12:37:52 PM
Script : http://.../foro/admincp/vba_dyna_import_vbposts.php?do=import&page=3&forumids=74,55,63,75,76,85,86,90,109,110,87,95,98,99,101,94,97,114,83,81,102,103 ,104,105,106,107,113,108,80,82,93,84,89,91,88,100,92,111,77,78,96,62,69,112&catids=3,4,5,7,8,9,10,11,13,14,16,17,20,21,22,23,24,25,27,30,57,58,59,31,32,33,3 4,46,40,41,42,43,44,45,47,48,49,50,54,55,51,52,53,56&forumkey=1&type=threads (\"http://news.google.com/news/url?sa=T&ct=us/1-0i-More...[/url)
Referrer : [url]http://.../foro/admincp/vba_dyna_import_vbposts.php?do=import&page=2&forumids=74,55,63,75,76,85,86,90,109,110,87,95,98,99,101,94,97,114,83,81,102,103 ,104,105,106,107,113,108,80,82,93,84,89,91,88,100,92,111,77,78,96,62,69,112&catids=3,4,5,7,8,9,10,11,13,14,16,17,20,21,22,23,24,25,27,30,57,58,59,31,32,33,3 4,46,40,41,42,43,44,45,47,48,49,50,54,55,51,52,53,56&forumkey=1&type=threads
IP Address :
Username : lms
Classname : vB_Database

You help me?

Thanks

tggbrokenwings
02-13-2008, 04:37 PM
no one can reply to posts after this install

No Entry specified. If you followed a valid link, please notify the administrator is whats being said

I can post NEW threads but not this..

what gives?

RaZor Edge
06-12-2008, 08:19 PM
Will this also work with 3.7.x?

Brian
06-13-2008, 06:42 PM
As far as I'm aware it will.

Magz
08-09-2008, 09:57 AM
I then got this

http://www.bapetalk2.com/uploads/import.png


and this is the error i got


Database error in vBulletin 3.6.2:

Invalid SQL:
INSERT INTO adv_dyna_entries (entryid, title, catid, userid, username, dateline, views, posts, iconid, valid, open, sticky, showsignature, votenum, votetotal, ipaddress) VALUES (
1,
'lookin\' good...',
3,
'4',
'johnnyblaze036',
'1170949274',
'36',
'0',
'0',
'1',
'1',
'0',
'0',
'0',
'0',
'208.196.60.42'
);

MySQL Error : Duplicate entry '1' for key 1
Error Number : 1062
Date : Tuesday, September 25th 2007 @ 08:10:34 AM
Script : http://dev.bapetalk2.com/admincp/vba_dyna_import_vbposts.php?do=import
Referrer : http://dev.bapetalk2.com/admincp/vba_dyna_import_vbposts.php?do=submitforums
IP Address : 66.108.233.115
Username : rollinjunk
Classname : vB_Database

Sounds like you had already submitted some entries to vBa Dynamics, and you have some threads/posts with conflicting id's. If you'll run these queries through phpMyAdmin or your vBulletin Admin CP then it should clear out all of that data.

TRUNCATE adv_dyna_entries;
TRUNCATE adv_dyna_entries_pages;
TRUNCATE adv_dyna_attachments;
TRUNCATE adv_dyna_entryparsed;
TRUNCATE adv_dyna_posts;
TRUNCATE adv_dyna_rate;

Will this also work with 3.7.x?



Brian, I imported a forum to a new category i created, and then ran the maintenence to update counters but got similar to this error. Ive tried running the queries you gave, but get

An error occurred while attempting to execute your query. The following information was returned.
error number: 1146
error desc: Table 'DATABASENAME_ibp.adv_dyna_entries' doesn't exist

Ive also noticed you cannot make a reply either, You can click the reply button, enter comment etc, but but when you submit it, No comments are being recorded. Ive ran maintenence options too.

Everything else with dynamics appears to work fine

Brian
08-11-2008, 03:40 PM
Looks like you need to add your table prefix before the table names in those queries.

TRUNCATE prefix_hereadv_dyna_entries;

Magz
08-11-2008, 05:11 PM
Thank you brian, that seemed to work.

However, i still cant post any comments. You enter a comment, press submit, no errors are shown, but it goes back to the post and the comment isnt being displayed.

Also, after running the query, content i had in some of the "non Imported" categories dissapeared.

Magz
08-14-2008, 03:07 PM
Any idea about the above message anyone ?

regards

Magz
09-08-2008, 12:35 AM
Not a great fan of bumping threads, but its been just over three weeks now, and i still cant get comments to display as mentioned 2 posts back.

Show Replies on Separate Page is set to no, and all permissions are set to allow posting replies.

Any ideas ?


Update:

Grrrr, what a numpty i am,

Category permisions were set to moderation, how i missed that i will never know.
Resolved :)

DrMirth
10-04-2008, 01:39 PM
I'm afraid I can't get this import script to work. I'm running vBulletin v3.7.3 Patch Level 1 and vBadvanced Dynamics v1.0.3. The script will allow be to select the forum to import from, but it the displays the following error:

PHP Fatal error: Call to undefined function print_cat_select() in vba_dyna_import_vbposts.php on line 55

Any ideas?

DrMirth
10-05-2008, 08:54 AM
Okay, I fixed my problem. A few functions needed to be prefixed with 'dyna_' before they would work. I've attached the updated script.

albumhunt
11-18-2008, 03:07 PM
each time i try to run the importer i get this msg
Your vBa Dynamics attachments folder is not writable. Please make sure that your '/home/users/public_html/downloads/attach' folder on your server is chmod to 777. Once you have updated this you may refresh the page to resume the import.

i noticed that its looking for the folder with the structure '/home/users/public_html/downloads/attach' but i dont have it that way..its setup as "/albumhunt.com/html/downloads/"

and i have triple checked those folder to make sure they writable.

btw vb ver 3.7.4 and the latest vb dyna

help?