Previous Thread
Next Thread
Print Thread
Rate Thread
#258709 09/12/2003 10:44 AM
Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
I tried using the send mass mail function and it only sent it out to about 30-40 adresses. It said sent to batch 1 of 1 and showed me the addresses it sent it to. I have version 6.3. any ideas on this one? I tried checking the send one at a time box and also tried uncehcking it. Got pretty much the same results every time. I have almost 700 registered users.

Sponsored Links
Joined: Jun 2003
Posts: 1,025
Junior Member
Junior Member
Offline
Joined: Jun 2003
Posts: 1,025
It is possible that most of your users have opted out the receive emails option. In 6.3 I believe you actually have to choose to opt in to recieve the emails.

You can run this sql querry to see how many have elected to recieve emails.

SELECT U_Username,U_Email
FROM w3t_Users
WHERE U_AdminEmails = 'On'

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
CAn you tell me how step by step to run that query? Sorry Im new at this..Thanks

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
nevermind I got it..and there are a ton of email addresses in there when i di the query..id say at least 400-500..any ideas?

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Admin -> SQL Query ->
Then enter that Query in the box.


This query might be better as it'll give you a count


SELECT COUNT (*)
FROM w3t_Users
WHERE U_AdminEmails = 'On'

Sponsored Links
Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
count is 340 and id say it only set to 30-40 people..Any ideas?

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
So does it do more than one page..... in other words.... it does all the plain text email first.......

Try this query

SELECT COUNT (*)
FROM w3t_Users
WHERE U_AdminEmails = 'On'
AND U_EmailFormat = 'html'

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
for html i get 10...for plain text query I get 32? Yes it sends plain text first and html second...32 plus 10 does not = 340..What gives?

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
So somehow people don't have the right email format.

Try this query:

UPDATE w3t_Users
SET U_EmailFormat = 'plaintext'
WHERE U_EmailFormat != 'html'


That should update all the emails without an email preference.

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
It says 1 row updated..does that sound right?
My database was imported about 3 months ago for Ubb classic if that helps at all.

Sponsored Links
Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
yeah, something might not have update right.


Try this:


SELECT COUNT(*)
FROM w3t_Users
WHERE U_AdminEmails = 'On'
SET U_EmailFormat = 'plaintext'


See what that count is.



Then do this:


SELECT COUNT(*)
FROM w3t_Users
WHERE U_AdminEmails = 'On'
SET U_EmailFormat = 'html'



If the numbers seem substantially higher.... try the email again. The emailer will cycle through all the plain text ones first.... then do the HTML mail.

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I suggest this one instead:

SELECT U_EmailFormat,COUNT(*)
FROM w3t_Users
WHERE U_AdminEmails = 'On'
GROUP BY U_EmailFormat

Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
Gotta Love the Master Jedi.

All Hail Dave!!

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
Just don't ask me how to tune MySQL.

Joined: Apr 2001
Posts: 3,266
Member
Member
Offline
Joined: Apr 2001
Posts: 3,266
LOL

I just love how you always come up with the ultimate QUERIES that combine functions when most of us know the BASIC ones.

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
ok to Dave L's query i get this

U_EmailFormat COUNT(*)
305
HTML 10
plaintext 33
Thoughts?

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
Josh Pet it says I have a syntax error in line 4 when trying to run your querys

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
I'm a tard. I copy and pasted and never properly edited.

OK 305 users still don't have an email preference defined.

Try this:

UPDATE w3t_Users
SET U_EmailFormat = 'plaintext'
WHERE U_EmailFormat <> 'html'

Then do Dave_L's query again.

Last edited by JoshPet; 09/13/2003 10:59 PM.
Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
1 row(s) affected by your query.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
[]JoshPet said:


Then do Dave_L's query again. [/]

And see if the numbers are better.

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
same thing
U_EmailFormat COUNT(*)
306
HTML 10
plaintext 33




Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
The UBB.threads SQL command function doesn't display NULL values correctly.

Try:

UPDATE w3t_Users
SET U_EmailFormat = 'plaintext'
WHERE U_EmailFormat <> 'html' OR U_EmailFormat IS NULL

Then repeat this query:

SELECT U_EmailFormat,COUNT(*)
FROM w3t_Users
WHERE U_AdminEmails = 'On'
GROUP BY U_EmailFormat

Might as well do this one too:

SELECT U_AdminEmails,COUNT(*)
FROM w3t_Users
GROUP BY U_AdminEmails

Last edited by Dave_L; 09/14/2003 9:55 PM.
Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
ok to the second two I got
U_AdminEmails COUNT(*)
337
Off 3
On 349


U_EmailFormat COUNT(*)
HTML 10
plaintext 339

so I guess with only 3 off and 680 registered users where are the other few hubdred in there?

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
They're probably either NULL or the empty string. I'm not sure whether the script interprets that as On or Off.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Try this...

UPDATE w3t_Users
SET U_AdminEmails = 'On'
WHERE U_AdminEmails <> 'Off'

then do Dave's query again.

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
You're forgetting about NULL again.

Joined: Nov 2001
Posts: 10,369
I type Like navaho
I type Like navaho
Joined: Nov 2001
Posts: 10,369
Oh so <> 'Off' won't update null huh?


Then :

UPDATE w3t_Users
SET U_AdminEmails = 'On'
WHERE U_AdminEmails IS NULL


Will that work?

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
I can never remember the rules for how NULL works with logical comparison operators. That's one reason why Rick should define all the columns as NOT NULL, unless there's really a good reason to do otherwise.

I would do:

UPDATE w3t_Users
SET U_AdminEmails = 'On'
WHERE U_AdminEmails <> 'Off' OR U_AdminEmails IS NULL

(This is assuming that you want to default to U_AdminEmails = 'On' for users who didn't indicate a preference, which increases the chances that someone might report you for spamming.)

And then do a SELECT query afterwards to see if it got everyone.

P.S. Here's a way of getting NULL values to show up as such when using the threads SQL command function (except the results would be misleading if there were any 'NULL', as opposed to NULL, values):

SELECT IF (U_Color IS NULL, 'NULL', U_Color) AS U_Color, COUNT(*)
FROM w3t_Users
GROUP BY U_Color

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
to the last query I got....yes i want the default to receive admin emails. now what?

U_Color COUNT(*)
683
#FF0000 5
NULL 1

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
That U_Color query was just a example for Josh. It has nothing to do with the emails.

Did you do this?

UPDATE w3t_Users
SET U_AdminEmails = 'On'
WHERE U_AdminEmails <> 'Off' OR U_AdminEmails IS NULL

And then do this to check the results, and post the output:

SELECT U_AdminEmails,COUNT(*)
FROM w3t_Users
GROUP BY U_AdminEmails

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
ok did both..for the second one i got....

U_AdminEmails COUNT(*)
Off 3
On 686

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
then i did your original query and got this

U_EmailFormat COUNT(*)
HTML 10
plaintext 676

So that should do it right?

Joined: Apr 2002
Posts: 1,768
Addict
Addict
Offline
Joined: Apr 2002
Posts: 1,768
Yes, the U_AdminEmails and U_EmailFormat columns look ok now. Wasn't that easy?

Joined: Jun 2003
Posts: 1,025
Junior Member
Junior Member
Offline
Joined: Jun 2003
Posts: 1,025
You have a funny definition of easy.

Joined: Jun 2003
Posts: 88
Power User
Power User
Offline
Joined: Jun 2003
Posts: 88
Hey thanks Dave and Josh pet for all your help!


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Posts: 70
Joined: January 2007
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20240506)