.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $5.00

   







Go Back   .com.unity Forums > The Camo Workshop > WinSPMBT > Campaigns, Scenarios & Maps
Notices


 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #4  
Old March 28th, 2019, 06:44 AM
DRG's Avatar

DRG DRG is offline
Shrapnel Fanatic
 
Join Date: Mar 2005
Location: GWN
Posts: 12,658
Thanks: 4,091
Thanked 5,862 Times in 2,893 Posts
DRG will become famous soon enough
Default Re: All U.S.M.C. Scenarios for 2019

You can run this in the version you already have simply cut and past it into the SQL window
it will show you every nation that Russia is the P2 opponent and add that to the 34 as P1

SELECT P1Name, P2Name, sYear, COUNT(sYear) AS Total
FROM ScenData.db
WHERE P2Name = "Russia"
GROUP BY sYear, P2Name, P1Name

That gives you the totals by year and by national opponent as P1

BUT with that version you MUST go to the SORT tab first and press Create Tables for it to find the info you are asking for with that SQL

That said pressing Create Tables the first time you use it and any time you make changes to Scenarios is best SOP

This one

SELECT P1Name, P2Name, COUNT(P2Name) AS Total
FROM ScenData.db
WHERE( LOWER(p2Name) like "%russia%")
GROUP BY P2Name, P1Name

Will total the number of scenarios Russia is the P2 opponent by nation but not by year. Also note the use of WHERE( LOWER(p2Name).....using LOWER allows you to enter the name in all lower case so it ignores capitols..useful if you are looking for all the SdKfz... it can be written sdkfz.

P1Name P2Name Total
Belgium Russia 1
Canada Russia 1
China Russia 4
Czechoslovakia Russia 1
Finland Russia 5
France Russia 2
GB Russia 4
Germany Russia 10
Greece Russia 1
Italy Russia 1
Japan Russia 1
Netherlands Russia 3
Norway Russia 5
Poland Russia 3
Romania Russia 2
Sweden Russia 8
U.S.Army Russia 28
U.S.M.C. Russia 6
Yugoslavia Russia 1


SQL's are powerful sorting tools but they aren't Google search... they give you exactly what you ask for but you must ask the question exactly right

This

SELECT P2Name, COUNT(P2Name) AS Total
FROM ScenData.db
WHERE( LOWER(p2Name) like "%russia%")
GROUP BY P2Name

Will give you one total..... and that is 87 as P2 ( in my files )

Also, keep in mind that when Sort tables runs it sorts through EVERYTHING in your scenario folders including Any WIP scenarios you might have
__________________


"You are never to old to rock and roll if you are too young to die".--- What do you expect to be doing when you are 80?


https://www.youtube.com/watch?v=8kWt8ELuDOc

Last edited by DRG; March 28th, 2019 at 07:47 AM..
Reply With Quote
The Following 3 Users Say Thank You to DRG For This Useful Post:
 

Bookmarks


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 On

Forum Jump


All times are GMT -4. The time now is 05:42 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.