PhotoPost Photo Gallery Sales PhotoPost Sales Toll Free Phone Number
Mon-Fri 9am-4pm EST
  PhotoPost Photo Sharing Photo Gallery    Visualize community tm
| | | | | | | | |

Go Back   PhotoPost Community > PhotoPost Support > vBGallery Support > vBGallery Suggestions

vBGallery Suggestions Post your comments, suggestions, and other feedback about PhotoPost vBGallery here.

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
Old April 29th, 2005, 11:09 PM   #1 (permalink)
Member
Verified Customer
 
Join Date: Jan 2003
Location: Gilbert, AZ
Posts: 394
Question username in lots of tables

I see lots of references to "username" in these tables. Why is that? If someone changes there username, what will happen to all these pictures, posts etc. that rely on username? Why not just use the userid as the foreign key and get the name from the one table that should be allowed to have the username, "user"?
7thgencivic.com is offline   Reply With Quote
Old April 29th, 2005, 11:18 PM   #2 (permalink)
Ultimate Member
Verified Customer
 
ConqSoft's Avatar
 
Join Date: Nov 2003
Location: Raleigh, NC
Posts: 1,413
Re: username in lots of tables

There's an option under the gallery maintenance to refresh those if you change any usernames.

I assume it's done to cut down on database hits doing all those joins... Dunno.
ConqSoft is offline   Reply With Quote
Old April 29th, 2005, 11:21 PM   #3 (permalink)
Member
Verified Customer
 
Join Date: Jan 2003
Location: Gilbert, AZ
Posts: 394
Re: username in lots of tables

i don't think that's a good idea. a join is nothing. I think i may change the queries for myself.
7thgencivic.com is offline   Reply With Quote
Old April 29th, 2005, 11:23 PM   #4 (permalink)
Ultimate Member
Verified Customer
 
ConqSoft's Avatar
 
Join Date: Nov 2003
Location: Raleigh, NC
Posts: 1,413
Re: username in lots of tables

Why add work for yourself? Do you have people changing their names all the time? I get maybe 2 name change requests a year.
ConqSoft is offline   Reply With Quote
Old April 29th, 2005, 11:38 PM   #5 (permalink)
Member
Verified Customer
 
Join Date: Jan 2003
Location: Gilbert, AZ
Posts: 394
Re: username in lots of tables

yes, i do. few a month. as a graduate in db design & dev, it just irks me to see bad db design. no offence to any of the devs, it's still great work. I noticed also that one of the username fields had a datatype of TEXT. thats a lot of space being reserved for nothing. It was prolly just an oversight tho.
7thgencivic.com is offline   Reply With Quote
Old April 29th, 2005, 11:41 PM   #6 (permalink)
Ultimate Member
Verified Customer
 
ConqSoft's Avatar
 
Join Date: Nov 2003
Location: Raleigh, NC
Posts: 1,413
Re: username in lots of tables

So did you change all the same stuff in vBulletin itself too?

thread table has postuserid, along with postusername, and lastposter is the text name of the user as well.

forum table stores the whole title of the last posted thread, along with the threadid, and also keeps up with the lastposter userid and username.

All this is done for a reason... Lots of joins will kill you in a high traffic situation. (But, you already know that since you're a graduate of database design. )
ConqSoft is offline   Reply With Quote
Old April 29th, 2005, 11:51 PM   #7 (permalink)
Ultimate Member
Verified Customer
 
ConqSoft's Avatar
 
Join Date: Nov 2003
Location: Raleigh, NC
Posts: 1,413
Re: username in lots of tables

(PhotoPost does it in a few places also, btw.)
ConqSoft is offline   Reply With Quote
Old April 30th, 2005, 10:58 AM   #8 (permalink)
Brian
Guest
 
Posts: n/a
Re: username in lots of tables

As ConqSoft said, it's to cut down on the number of joins and strain on the server. Which is more expensive, extra server space, or a better server? Even on my personal site with over 10,000 images the adv_gallery_images table only takes up 1.4mb.
Where are you seeing a useraname column that's defined as a text column? I just looked through the database structure and I'm not seeing one...
  Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
performance of vBadvanced Gallery with lots of images dontom Before You Buy 12 October 25th, 2005 01:42 PM
lots of errors on 3.01(NOT A BUG) 7thgencivic.com ReviewPost Bug Reports 4 September 3rd, 2005 10:32 AM
Lots of errors after upgrades Quincy Wisdom Photopost Pro Installation & Upgrades 4 June 30th, 2005 03:25 PM
Before Step 5, Lots of fopen fclose errors Layne Smith Photopost Pro Installation & Upgrades 19 April 23rd, 2005 10:07 PM


All times are GMT -5. The time now is 08:18 PM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0