Redisplay form data after insert shows wrong style

This used to work and something got messed up.
I have a form that the user fills in. The user clicks insert and the record is created. I want to then keep the form and data displayed, but want to enable some tabs.
What is happening is this: The form is redisplayed, but not with the record I just created. It is displaying the MIN record number as you see in the SQL below. Have no idea where this comes from.
I tried a redirect to itself, but that didn’t work for me.
Any help is appreciated
TY

this shows how Style #491 was created, but 445 is displayed after the insert

(pdo-mysql): SELECT LAST_INSERT_ID()

current style created is 491
running style create7
(pdo-mysql): SELECT BuyerInitials FROM tblBuyer WHERE buyerid = ‘4’
(pdo-mysql): SELECT count() FROM tblStyle WHERE deleteDate = ‘2025-08-28’ and buyer = ‘4’ and showit = 1 and active = 1;
SN is 29
(pdo-mysql): SELECT count(
) FROM tblStyle WHERE deleteDate = ‘0’ and buyer = ‘4’ and showit = 1 and active = 1;
SO is 0
(pdo-mysql): DELETE FROM tblCalendar WHERE firstDate = ‘2025-08-28’ and category = ‘8’ and buyerid = ‘4’
(pdo-mysql): DELETE FROM tblCalendar WHERE firstDate = ‘0’ and category = ‘8’ and buyerid = ‘4’
sn is 29
(pdo-mysql): SELECT styleid FROM tblStyle WHERE deletedate =‘2025-08-28’ and buyer = ‘4’ and showit = 1 and active = 1; LIMIT 3
(pdo-mysql): INSERT INTO tblCalendar (category, Title, Title2, user, firstDate, lastdate, frequency, buyerid) VALUES (‘8’, ‘29 Style Delete: BO’, ‘Style : 445 447 448… click for more’, ‘lewis’, ‘2025-08-28’, ‘2025-08-28’, ‘29’, ‘4’)
(pdo-mysql): SELECT * FROM tblCalendar WHERE category = ‘5’ and firstDate = ‘2025-07-29’
(pdo-mysql): SELECT count() FROM tblStyle WHERE lastViewedDate = ‘2025-07-29’;
(pdo-mysql): SELECT category, frequency FROM tblCalendar WHERE category = ‘5’ and firstDate = ‘2025-07-29’
(pdo-mysql): UPDATE tblCalendar SET frequency = ‘30’, Title2 = ‘Styles: 30’ WHERE category = ‘5’ and firstDate = ‘2025-07-29’
(pdo-mysql): SELECT styleid, altStyleCode1, VendorStyleCode, rangeid, imupc, name, lastCost, notepad, vendorid, buyer, classid, subdepartmentid, xclassCode, xsubDepartmentCode, departmentCode, season, seasonYear, dateordered1, dateorderedLast, dateReceived1, lastViewedDate, dateReceivedLast, dateMD1, dateMDLast, dateSold1, dateSoldlast, lastMDPercent, basic, online, createdDate, deleteDate, replacesStyle, retail1, retailLast, retailCurrent, retailNext, UM, weight, lastReceivedQty, altStyleCode2, cost1, averageCost, LCPortion, landedCost, dateCreated, active, user, company, lifeStyle, Gender, photo1, Photo2, Photo3, Photo4, Photo5, altVendor1, altVendor2, altVendor3, altVendor4, IMU, showit, unitWeight, unitVolume, hdrval, lcCode, ddid, mdpcf, lastCountDate, PreviousStyleNumber, buyerRestricted from tblStyle WHERE (styleid = 445 and rangeid = 131) order by styleid, rangeid
(pdo-mysql): SELECT COUNT(
) AS countTest FROM tblStyle

(pdo-mysql): SELECT COUNT(*) AS countTest FROM tblStyle WHERE ((styleid < 445) OR (styleid = 445 AND rangeid < 131))