The code is originally generated with querybuilder, modified by me
How to create SQL dynamic questions that can take input from other functions. This makes the SQL-question more dynamic.
For date generation look at med entry about generate_date_from_uicalendar
can any one tell i insert data in database through GUI like making some Edit text boxes and Button in GUI and When User click the All Data Is saved in Database please tell me For MS access Database
"Dynamic" sounds pretty unsuited for this submission since its use has meaning only to the Author.
It would take me less time to write down a query from the beginning than modifying the output of your fcn.
Not to count the time needed to read what the fcn actually accomplishes...
Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.