Production under the plan, every day there are a lot of data in the data window, and we just want to see the record of the plan a day, through the screening period, edit, save and copy or insert table next procedure, how to implement? Expert help!
CodePudding user response:
String ls_start ls_end, ls_select//get the start and end time
Ls_start=em_start. Text
Ls_end=em_end. Text
Ls_select='
//start time
If not isnull (ls_start) and ls_start & lt;> "" and the lower (ls_start) & lt;> 'none' then
Ls_select=ls_select + "convert (char (10), plandate, 120) & gt;='" + ls_start + "
"End the if
//end time
If not isnull (ls_end) and ls_end & lt;> "" and the lower (ls_end) & lt;> 'none' then
If ls_select="" then
Ls_select="convert (char (10), plandate, 120) & lt;='" + ls_end + "
"The else
Ls_select=ls_select + "AND the convert (char (10), plandate, 120) & lt;='" + ls_end + "
"End the if
End the if
//spelling a SQL statement
Ls_select=is_sql + 'where' + ls_select
If ls_select & lt;> "' then
//assignment SQL statement
Dw_1. Setsqlselect (ls_select)
End the if
Dw_1. Retrieve ()//retrieve data
CodePudding user response:
Two options:One is the background, get a stored procedure, according to your condition, implementation into action.
Another kind is the front desk, all the data in the data window to state to another window, through the data window update ~
CodePudding user response:
Hello, have specific code?CodePudding user response:
At the front desk are there any specific code realization, come onCodePudding user response:
I'm online, etc., and pointsCodePudding user response:
Access, SQL, perform,,,,CodePudding user response:
The original poster can give up the PBCodePudding user response:
Rowscopy after the updateCodePudding user response:
Rowscopy only limits to field was cycleCodePudding user response:
1, retrieved data needs to be some people change, then save, upstairs said there is no way to realize the storage process,2, two table structure is the same, can use rowscopy way, different structures will read line by line, setitem to another form,
CodePudding user response:
You don't know the structure of the two tables, the building Lord how are you going to the somebody else give you code?CodePudding user response:
Retrieve the data, after editing, directly inserted into the target in the tableCodePudding user response:
With SETFILTER first filter (), then use the SQL formation process of data,CodePudding user response:
Data window has several functions, is a common, such as rowscopy SHAREDATA, time is long can't remember the exact parameters, you can find out the online help for PB,In addition, according to your description, can be directly dw_1, retreive (' time fields'=specific time), for example, the specific time for getitemstring (dw_2. Time)